Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

I. Use the Pep/8 Virtual Computer to answer the following question. Make sure th

ID: 3804718 • Letter: I

Question

I. Use the Pep/8 Virtual Computer to answer the following question. Make sure the Code/CPU/Memory view is selected.

Write a program in Assembly Language that displays your first name on the screen (name: Mario). Assemble/Load/Run the source code.  

Copy the source code from the “Assembler Listing” window & paste it below - make sure all the program code is shown.

II. Use the Pep/8 Virtual Computer to answer the following question. Make sure the Code/CPU/Memory view is selected.

Write a program in Assembly Language that prompts the user for two numbers (i & j) and displays the result of calculating i - j + 2. Assemble/Load/Run the source code.  

Copy the source code from the “Assembler Listing” window & paste it below - make sure all the program code is shown.

Explanation / Answer

A virtual computer, like the Pep/8 machine, simulates the processing of a real computer. Both can be programmed in a form of machine language and assembly language code, but the virtual computer is really just a program that processes those instructions and produces a result. The machine language of an actual computer is executed through the circuitry of the CPU. A virtual computer simplifies some of the details involved and creates a nice environment for exploring low-level computing issues without getting too bogged down in the details of a real CPU’s machine language. Thus, a virtual computer is another example of an abstraction.