Use range based loop for output.

This commit is contained in:
Max Luebke 2022-03-01 19:48:18 +01:00
parent 2465911659
commit 374a7ef9d9

View File

@ -43,8 +43,8 @@ int main(int argc, char *argv[]) {
cout << "Iteration: " << i << "\n\n";
for (int j = 0; j < field.size(); j++) {
cout << field[j] << "\n";
for (auto & cell : field) {
cout << cell << "\n";
}
cout << "\n" << endl;