Postfix Calculator Tests

Tom Kelliher, CS 220

Oct. 28, 2011

Your postfix calculator should be able to do all the following, just like postfix.c:

12
12 34 +
12 34 -
12 34 *
12 34 /
34 12 /
12 34 56 78 90 + + + +
12 34 + 56 + 78 + 90 +
1 2 3 4 5 6 7 8 + + + + + + +
2 3 + 4 5 + *
2 3 4 * + 5 +
2 3 4 * 5 + +
-12 -34 -
q
12 12                   (Error message)
12 -                    (Error message)
12 0 /                  (Error message)
1 2 3 4 5 6 7 8 9       (Error message)
a                       (Error message)



Thomas P. Kelliher 2011-10-27
Tom Kelliher