home *** CD-ROM | disk | FTP | other *** search
- Xref: sparky alt.hackers:1359 talk.bizarre:28733
- Newsgroups: alt.hackers,talk.bizarre
- Path: sparky!uunet!ulowell!news.bbn.com!usc!cs.utexas.edu!hellgate.utah.edu!fcom.cc.utah.edu!fcom.cc.utah.edu!jon
- From: jon@zeus.med.utah.edu (Jonathan Byrd)
- Subject: Re: Your very own Magic 8 Ball simulator
- In-Reply-To: jim@rand.org's message of 3 Sep 92 04:05:43 GMT
- Message-ID: <JON.92Sep3103952@zeus.med.utah.edu>
- Sender: news@fcom.cc.utah.edu
- Organization: University of Utah
- References: <1992Sep1.232614.15386@wdl.loral.com>
- <1992Sep3.014309.1325@terminator.cc.umich.edu> <3760@randvax.rand.org>
- Date: 3 Sep 92 10:39:52
- Approved: Yes!
- Lines: 40
-
- In article <3760@randvax.rand.org> jim@rand.org (Jim Gillogly) writes:
-
- #!/usr/bin/perl
-
- srand(time|$$);
- print
- (
- "YES.",
- "You may rely on it.",
- "It is decidedly so.",
- "Yes, definitely.",
- "Without a doubt.",
- "It is certain.",
- "Most likely.",
- "Outlook good.",
- "Signs point to `yes.'",
- "As I see it, yes.",
- "Reply hazy, try again.",
- "Concentrate and ask again.",
- "Ask again later.",
- "Better not tell you now.",
- "Cannot predict now.",
- "My sources say, `No.'",
- "Very doubtful.",
- "Don't count on it.",
- "Outlook not so good.",
- "My reply is: No."
- )[rand(20)] . "\n";
-
- pah! you're not done yet. where the fuck is the part that parses the
- input?
-
- example:
-
- if(x = strcmp(input_string, "Should I staple myself to the carpet and
- beg mommy to vacuum-fuck me?") == 0) printf("Without a doubt.\n")
-
- --
- jonathan byrd
- jon@apollo.med.utah.edu
-