You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: solution/0200-0299/0289.Game of Life/README_EN.md
+6-2
Original file line number
Diff line number
Diff line change
@@ -18,7 +18,7 @@ tags:
18
18
19
19
<!-- description:start -->
20
20
21
-
<p>According to <ahref="https://en.wikipedia.org/wiki/Conway%27s_Game_of_Life"target="_blank">Wikipedia's article</a>: "The <b>Game of Life</b>, also known simply as <b>Life</b>, is a cellular automaton devised by the British mathematician John Horton Conway in 1970."</p>
21
+
<p>According to<ahref="https://en.wikipedia.org/wiki/Conway%27s_Game_of_Life"target="_blank">Wikipedia's article</a>: "The <b>Game of Life</b>, also known simply as <b>Life</b>, is a cellular automaton devised by the British mathematician John Horton Conway in 1970."</p>
22
22
23
23
<p>The board is made up of an <code>m x n</code> grid of cells, where each cell has an initial state: <b>live</b> (represented by a <code>1</code>) or <b>dead</b> (represented by a <code>0</code>). Each cell interacts with its <ahref="https://en.wikipedia.org/wiki/Moore_neighborhood"target="_blank">eight neighbors</a> (horizontal, vertical, diagonal) using the following four rules (taken from the above Wikipedia article):</p>
24
24
@@ -29,7 +29,11 @@ tags:
29
29
<li>Any dead cell with exactly three live neighbors becomes a live cell, as if by reproduction.</li>
30
30
</ol>
31
31
32
-
<p><span>The next state is created by applying the above rules simultaneously to every cell in the current state, where births and deaths occur simultaneously. Given the current state of the <code>m x n</code> grid <code>board</code>, return <em>the next state</em>.</span></p>
32
+
<p><span>The next state of the board is determined by applying the above rules simultaneously to every cell in the current state of the <code>m x n</code> grid <code>board</code>. In this process, births and deaths occur <strong>simultaneously</strong>.</span></p>
33
+
34
+
<p><span>Given the current state of the <code>board</code>, <strong>update</strong> the <code>board</code> to reflect its next state.</span></p>
35
+
36
+
<p><strong>Note</strong> that you do not need to return anything.</p>
0 commit comments