给定这样的输入:3+4+ 算法将其转换为3 4 + +
3+4+
3 4 + +
我可以在执行后缀表达式时找到错误.但是,有可能在转换期间发现这一点吗?
(我读过的维基百科文章和网络文章不处理这种情况)
谢谢
parsing infix-notation postfix-notation shunting-yard
infix-notation ×1
parsing ×1
postfix-notation ×1
shunting-yard ×1