This preview has intentionally blurred sections. Sign up to view the full version.View Full Document
Unformatted text preview: D EUS X ERCISES Part I. The memory of the Deus X Machine has been loaded with instructions as shown on the following page. We have also given an assembly language version of the program, which may help you a bit in following it. The input data consists of 5 lines in a file, as shown below; the fifth line is blank. 7 9 4 6 (blank line) Please answer the following questions about the program that appears on the next page. (a) Trace through the execution of this program. From time to time, a new value gets stored in reg- ister A. As you follow the execution of the program, write down, in order, each new value that gets stored in register A. (b) What answer does this program print out? (c) In one or two plain English sentences, describe what task this program performs. Your descrip- tion should not just describe the operations ("First it puts zero into the A register ..."); rather, it should be something we could put in a software catalog so that a prospective buyer could know what the program does....
View Full Document
- Winter '10
- Following, Control flow, University of California, Irvine, david g. kay