Difference between revisions of "CSC103 Assembly Language Exercises"

From dftwiki3
Jump to: navigation, search
(Created page with "--~~~~ ---- ==Exercises on Assembly Language== === ''LOD-C 1'' === ::::<font color="magenta">Exercise 1:</font> initialize the contents of several variables to 0 === ''LOD 10'' ...")
 
 
Line 27: Line 27:
  
 
<br />
 
<br />
 
+
[[CSC103 Assembly Language Exercises and Solutions |.]]
 
<br />
 
<br />
 
 
<br />
 
<br />
  
Line 43: Line 42:
  
 
<br />
 
<br />
 +
<onlydft>
 +
[[CSC103 Assembly Language Exercises and Solutions| Solutions]]
 +
</onlydft>
  
 
<br />
 
<br />
 
[[Category:CSC103]][[Category:Exercises]]
 
[[Category:CSC103]][[Category:Exercises]]

Latest revision as of 07:45, 20 February 2012

--D. Thiebaut 06:43, 20 February 2012 (EST)


Exercises on Assembly Language

LOD-C 1

Exercise 1: initialize the contents of several variables to 0

LOD 10

Exercise 2: increment a counter
Exercise 3: compute sum of 3 variables

LOD-I 10/STO-I 10

Exercise 4: create an index and use it to sum up the same 3 variables

Loops (infinite loop)

JMP instruction and labels

Exercise 5: create an infinite loop (incrementing a variable, for example)
Exercise 6: create an infinite loop that clears the memory starting at 10
Exercise 7: why does the program of Exercise 6 stop?

Controlled Loops: JMZ

Exercise 8: write a loop that loops 10 times (use a counter)
Exercise 9: write a loop that stores 55 in the memory locations between 15 and 30




.








...