Question: Suppose you are implementing a simple computer system that works by loading data into registers and then applying an operation to them. You will include

Suppose you are implementing a simple computer system that works by loading data into registers and then applying an operation to them. You will include a compiler for a simple programming language, and a trivial job scheduler that just runs programs in the order submitted. Which is most suited for the following purposes? Hint: Use each once.

  1. A. Doubly Linked Lists
  2. B. Hash Tables
  3. C. Stacks
  4. D. Queues
  5. E. Binary Trees

Keeping track of definitions associated with symbols (e.g. foo <- function (x) ...)

Representing parsed expressions so you can convert inorder expressions such as "x + y" into the postorder sequence "x y +" needed by your hardware

Keeping track of active subprocedure calls to be continued

Keeping track of the order in which programs should be run

Can be used to implement many of the other ADTs on the list

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!