X-Git-Url: https://git.xandkar.net/?p=cellular-automata.git;a=blobdiff_plain;f=003%2Fsrc%2Flife.erl;h=5f91d2681430aecd29ccc47b50f14eb1224dc9bd;hp=74868da09e63fe754a3bb5938080eead4d11e432;hb=160a4566dcc36d03f6af95e7c588cc7453fdd905;hpb=1332e0c3c23643c3eeac5e3d7a64dcac4591e488 diff --git a/003/src/life.erl b/003/src/life.erl index 74868da..5f91d26 100644 --- a/003/src/life.erl +++ b/003/src/life.erl @@ -61,7 +61,12 @@ life_loop( end ), - {NewTime, NewBoard} = timer:tc(fun() -> next_generation(X, Y, Board) end), + {NewTime, NewBoard} = timer:tc( + fun() -> + next_generation(X, Y, Board) + end + ), + NewState = State#state{board = NewBoard ,gen_count = GenCount + 1 ,gen_duration = NewTime