Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: Re: If God wrote a Perl script

by danger (Priest)
on Jan 03, 2001 at 04:04 UTC ( #49428=note: print w/ replies, xml ) Need Help??


in reply to Re: If God wrote a Perl script
in thread If God wrote a Perl script

I think God used to be more hands on, but he long since automated much of the grunt work:

#!/usr/bin/perl -w use strict; # face it, God is strict and gives warnings use Create; while(1){ my $universe = Create->new(); $universe->first_seven_days(); while(1){ last unless universe->still_has_life(); $universe->random_cataclysm() if int(rand(10000)) == 666; $universe->random_miracle() if int(rand(1000)) == 7; } print "Do you want to play again?[y/n] "; chomp(my $answer = <STDIN>); last if $answer =~ /^n/i; } __END__


Comment on Re: Re: If God wrote a Perl script
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://49428]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (5)
As of 2014-09-21 12:10 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (168 votes), past polls