Lab 4


This lab will build upon what you have learned in Labs 2 and 3, as well as familiarize you with the stack.

Submit: rpn.mal, README

Files:

Problem: Write a non-recursive RPN calculator that takes a variable number of integer inputs and character operations.

Example:

	Welcome to my RPN Calculator!
	Enter a string of positive integers and operations separated by spaces!
	> 72 23 8 13 + - *
	The result is 144
	The square root of 144 is 12!  (*)

(*) just kidding!  You don't have to do square roots.

Internals: Here is how your stack looks at the end of your input loop:

           <sp>
                13
                8 
                23
                72	
	

Here is how you calculate the result:
		(72 (23 (8 13 +) -) *)
	

If you need a refresher on what an rpn calculator is, see the rpn help page.

Notes/Requirements:

Collaboration with other students is allowed on this lab assignment! Make SURE you give other students and tutors credit for any help you receive and any code you develop together. Even if you develop some code with someone else and give credit, it still must be your own! This means if you can't write it, you can't use it! Give credit to any help you receive. Rewrite all your code "in your own words" to guarantee that it really is yours. And give credit. Give credit.

Evaluation: your lab tutor will assign one of following grades: check +, check, check -, 0

NOTE: A BAD OR MISSING README WILL DROP YOUR SCORE BY ONE FULL GRADE!