subject

Define a SCHEME function, named (eval-postfix p), that will take postfix expression (stored in a list of integers representing operands and characters representing operators), evaluate that expression, and return the result. Your function should support the operations of addition (#+), subtraction (#-), multiplication (#*), divi- sion(#/), and exponentiation(#\ˆ). You may want to work incrementally by starting with a function that takes a character representing an operator and can pop two operands off of a stack, evaluate the operator and push the result back on the stack. Next you can add a function that evaluates a postfix expression by pushing operands onto the stack and evaluating operators when encountered. Note, you may want to use the number? function to determine whether an item in the list is an operand or an operator.

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 17:30
1. before plugging in a new device to a computer you should unplug all other devices turn off the computer turn on the computer 2. many of the maintenance tools for a computer can be found in the control panel under administrative tools display personalization
Answers: 1
question
Computers and Technology, 23.06.2019 15:00
Jake really works well with numbers and is skilled with computers but doesn't work well with others. which of the jobs discussed in this unit might be best for jake? why?
Answers: 3
question
Computers and Technology, 24.06.2019 15:30
Emma is using an artificial intelligence system, which contains information on botany, to identify a type of plant from an image. what type of ai is emma using?
Answers: 1
question
Computers and Technology, 24.06.2019 17:30
Looking at the electroscope, describe how you can cause the two leaves at the bottom to repel each other and stay that way
Answers: 3
You know the right answer?
Define a SCHEME function, named (eval-postfix p), that will take postfix expression (stored in a lis...
Questions
Questions on the website: 13722360