PYTHON   92

Run

Guest on 30th April 2022 11:58:27 PM

  1. # this is a driver program that connects to the Parse and Eval files and
  2. # calls their main functions.
  3.  
  4. import Parse
  5. import Eval
  6.  
  7. tree = Parse.parse()
  8. print
  9. print "operator tree =", tree
  10. print
  11. answer = Eval.eval(tree)
  12. print
  13. print "final answer =", answer
  14. print
  15. raw_input("Press Enter to quit")

Raw Paste


Login or Register to edit or fork this paste. It's free.