Skip to content
Snippets Groups Projects
Commit 434a974f authored by arthur's avatar arthur
Browse files

implémentation de la méthode clear

parent 37bdfe78
Branches
No related tags found
No related merge requests found
......@@ -149,6 +149,10 @@ public class Grid implements Iterable<Cell> {
* Sets all {@link Cell}s in this {@code Grid} as dead.
*/
void clear() {
GridIterator iterator = new GridIterator(this);
while (iterator.hasNext()) {
iterator.next().setDead();
}
}
/**
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment