in reply to Golf -- compute PI
use integer;$|++;my@e=(1)x5e3;for(a..zzz){$e[$_-1]+=$e[$_]/$_,$e[$_]%= +$_ for reverse 1..$#e;print$e[0];$e[0]=0;$_*=10for@e;}
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: Golf -- compute PI
by thospel (Hermit) on Jan 21, 2007 at 12:21 UTC |