Add exceptions to rpn algorithm and exception handling to the
calculator. But still some bugs remain in the rpn.