Difference between revisions of "CSC231 Homework 6 2017"

From dftwiki3
Jump to: navigation, search
Line 131: Line 131:
 
* '''N''' is a nasm constant that is equal to the number of bytes (or cells) in '''dish'''.
 
* '''N''' is a nasm constant that is equal to the number of bytes (or cells) in '''dish'''.
 
* '''maxGen''' is the maximum number of generations your program should output.  Since the program prints the initial generation of cells plus '''maxGen''' generations, the total number of lines your program will output should be equal to '''maxGen + 1'''.
 
* '''maxGen''' is the maximum number of generations your program should output.  Since the program prints the initial generation of cells plus '''maxGen''' generations, the total number of lines your program will output should be equal to '''maxGen + 1'''.
<font color="magenta">Note that in the Game of Life program we generated in class together, I used 20 as the number of generations.  In your new version, you shouldn't use a constant, but rather whatever number is in the int variable '''maxGen'''.
+
<font color="magenta">Note that in the Game of Life program we generated in class together, we used 20 as the number of generations.  In your new version, you shouldn't use a constant, but rather whatever number is in the int variable '''maxGen'''.
 
<br />
 
<br />
 
==Running the Demo Program==
 
==Running the Demo Program==
Line 141: Line 141:
 
   !              ! ! ! ! ! ! ! !                !
 
   !              ! ! ! ! ! ! ! !                !
 
   
 
   
 +
* You should verify that it prints the ASCII version of the '''dish''' array defined in the ''dishArray.inc'' file.
 +
* For fun, modify the 0s and 1s inside the array '''dish''', in the '''dishArray.inc''' file (you may remove some, or add new 1s or 0s), and assemble, link, and run the demo program again.  You should see the new output reflect your changes.
 
<br />
 
<br />
  

Revision as of 20:16, 1 April 2017

--D. Thiebaut (talk) 18:56, 1 April 2017 (EDT)


Game Of Life Without Loop Instructions


For this assignment, you need to write a game of life program in assembly, and the challenge is to implement it without using the loop instruction, using only the cmp instruction and conditional jumps.



...