辅导CSCI 1060U、讲解C/C++、辅导Tic-Tac-Toe、讲解C/C++编程语言
- 首页 >> C/C++编程CSCI 1060U - Laboratory #9
(More) Programming Tic-Tac-Toe
Lab Due: midnight two days after your lab (Blackboard)
Introduction
The main purpose of this lab is to implement a two-dimension dynamic array.
Activity #1
You should start by downloading the tictactoe_final.cpp program
(http://www.sqrlab.ca/exercises/tictactoe_final.cpp) (alternatively you can start
from your Laboratory 6 submission). This program uses a two-dimensional array
for the tic-tac-toe board that is implemented using an ordinary (automatic)
variable:
string board[SIZE][SIZE];
For this lab you need to modify the board array to be implemented using dynamic
variables and update the rest of the program accordingly.
(Hint: a two-dimensional dynamic array is created using a pointer to an array of
pointers)
You should submit your source file (.cpp) for Activity #1 through the lab drop box
in Blackboard.