in reply to Use radio noise to make (non-critical) decisions...
use strict; use Quantum::Entanglement; $|++; print "Welcome to the magic 8 ball...type 'leave' to exit\n"; for(;;){ my $answer = entangle(1, 'Outlook Good', 1, 'Outlook Not So Good', 1, 'My Reply Is No', 1, 'Don\'t Count On It', 1, 'You May Rely On It', 1, 'Ask Again Later', 1, 'Most Likely', 1, 'Cannot Predict Now', 1, 'Yes', 1, 'Yes Definately', 1, 'Better Not Tell You Now', 1, 'It Is Certain', 1, 'Very Doubtful', 1, 'It Is Decidedly So', 1, 'Concentrate and Ask Again', 1, 'Signs Point to Yes', 1, 'My Sources Say No', 1, 'Without A doubt', 1, 'Reply Hazy, Try Again', 1, 'As I See It, Yes'); print "What is your question: "; my $ans = <STDIN>; chomp $ans; exit if $ans=~/^leave$/i; print "Rolling"; for(1..4) { sleep 1; print "."; } print "\n$answer\n"; }
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: Use radio noise to make (non-critical) decisions...
by Aristotle (Chancellor) on Jan 11, 2003 at 20:28 UTC |