Building C++ Classes
Convert C program--> C++
Basic C++ Quiz
Similarities in C/C++
Using IO Stream - Exercise
Scope of Function
Functions Variables - Conclusion
Functions Scope - Quiz
Pointers Memory Allocation
C++ const keyword
const pointer argument
Call by Reference
C++ Generic Pointer
void formal Parameter
Free Store Operators
C++ new Operator
C++ delete Operator
array allocation Function
array deallocate Function
C++ main function
memory Allocation Conclusion
Pointers Memory Allocation - Quiz
Course project output routine
Write a display routine for the life simulation course project.
The life simulation will be played on a 10 by 10 "life board." Each cell of the board will either be empty or "alive."
Create a two-dimensional array for the board. Use this array to store information and to display the board.
Since you have not developed the game yet, you can initialize the board with random X's or 1's to indicate a cell that is alive.
You can easily do this when you display the board by checking
modulus 2. If this equals 1, then display an X in the cell. If
modulus 2 equals 0, then do not display an X.
Be sure to use function prototypes in your code.
Run your program several times and make sure the board content is being initialized differently each time.
Paste the source code of your program below and click the
button when you are ready to submit this exercise.