Question: Core War is a programming game introduced to the public in the early 1980s [DEWD84], which was popular for a period of 15 years or
CodeBlue contains only five assembly language statements and uses three addressing modes (Table B.4). Addresses wrap around, so that for the last location in memory, the relative address + 1 of refers to the first location in memory. For example, ADD #4, 6 adds 4 to the contents of relative location 6 and stores the results in location 6; JUMP @5 transfers execution to the memory address contained in the location five slots past the location of the current JUMP instruction.
a. The program Imp is the single instruction COPY 0, 1.What does it do?
b. The program Dwarf is the following sequence of instructions:
ADD #4, 3
COPY 2, @2
JUMP -2
DATA 0
What does it do?
c. Rewrite Dwarf using symbols, so that it looks more like a typical assembly language program.
Step by Step Solution
3.41 Rating (170 Votes )
There are 3 Steps involved in it
a When it executes this instruction copies itself to the next location and the program counter is in... View full answer
Get step-by-step solutions from verified subject matter experts
Document Format (1 attachment)
896-C-S-S-A-D (2695).docx
120 KBs Word File
