life.h
来自「数据结构与程序设计教材源码 数据结构与程序设计教材源码」· C头文件 代码 · 共 13 行
H
13 行
const int maxrow = 20, maxcol = 60; // grid dimensions
class Life {
public:
void initialize();
void print();
void update();
private:
int grid[maxrow + 2][maxcol + 2]; // allows for two extra rows and columns
int neighbor_count(int row, int col);
};
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?