Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options

Re: Game of Life

by teamster_jr (Curate)
on Sep 22, 2006 at 09:27 UTC ( [id://574347] : note . print w/replies, xml ) Need Help??

in reply to Game of Life

print"\ec";for$b(0..15){$e[$b].=int 2*rand for 0..($h=30)}{$b=-1;for$f +(@ a=@e){$e[++$b]="";print"\e[$b\H$f$/";for$c(0..$h){$l=0;for($b-1..$b+1) +{$ _=$_>0&&$_<$h?substr$a[$_],$c?$c-1:$c,$c==$h?2:$c?3:2:1;$l+=tr/0//}$l- +=$ d=!substr$f,$c,1;$e[$b].=$l==3||$l==2&&$d?0:$"}}select$q,$q,$q,0.1;red +o}
288 chars ;)
from here

edit: ps. probably needs vt100 terminal