perl -e ' $runs = 10000000 ; do { $x = rand(1); $y = rand(1); $cnt++ i +f $x*$x + $y*$y>1 } foreach (1 .. $runs); print 4*(($runs-$cnt)/$runs +)."\n"' [download]
Ah, Monte Carlo.... :)
Enjoy your pi, folks!
www.com | www.net | www.org
No recent polls found