|
DataMuseum.dkPresents historical artifacts from the history of: DKUUG/EUUG Conference tapes |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about DKUUG/EUUG Conference tapes Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - downloadIndex: T p
Length: 9493 (0x2515) Types: TextFile Names: »psychic.c«
└─⟦b20c6495f⟧ Bits:30007238 EUUGD18: Wien-båndet, efterår 1987 └─⟦this⟧ »EUUGD18/General/Psychic/psychic.c«
/***************************************************************************** * PSYCHIC.C Version 1.0 * * This program is attuned to the Powers of the Ancients, and the * Mysterious Forces which Shape our Destiny. With This Program, You * will Be Privy to the same Sources of Knowledge and Mystic Oracles * used by Ancient Astronauts. * * Know that this Font of Wisdom will work on BSD Unix Systems Unmodified, * but the Ancients have Decreed that you must change "#undef SYSV" to * "#define SYSV" in the Line Below if you have the System of Fives. * * When Who Why * ============== ======= ============================================== * v1.0 06/17/87 14:46 BVH Wrote this comment. ******************************************************************************/ #include <stdio.h> #define MAXCOL 78 #undef SYSV #ifdef SYSV #define srandom srand #define random rand #endif #undef DRI char *emotion[] = { /* ~E */ "Hope","Love","War","Peace","Pestilence","Plague","Lust","Justice", "Travel","Cost of Living","Inflation","Oblivion","Television", "Choice","Blind Beggars","Ugliness","Beauty","Bad Breath", "Country Living","Utter Dullness","Pillow Talk","Evil","Good", "Water","Air","Death","Situation Comedies","Supermarket Rags", "Rock and Roll","Light","Dark","Knowledge","Anatomy","Psyche", "Vengeance","Destruction","Wallpaper","Wisdom","Babysitters", "Drinking","Filth","Flat Squirrels on the Highway","Gossip about ~N", "Dumb Novelty Programs (like this one)" }; char *whatis[] = { /* ~W */ "the Ram","the Bull","the Fish","the Crab","the Centaur","the Virgin", "the Scorpion","the Water Bearer","the Twin","the Lion","the Turtle", "the Merciless","the Scourge of Heaven","the Patron of ~E", "the Guardian of ~E","the Goddess of ~E","the God of ~E", "the Horse","the Birdman of Alcatraz","the Source of All ~E", "the Jedi Master","the WWF Champion","the Comic Sensation", "the ~N Lookalike","the Wise","the Small","the Elder", "Scion of the Elder Race","the One with the Power of ~E", "the One who Brings ~E","the One Who Fights ~E", "the Polka Dotted","the Consort of ~W","the Ruler of ~E", "the One who Predicts That ~P","the Sucker of Dust","the Twin Tower", "the One and Only","the Speaker for ~E","the Gweat and Powerful", "the Psychic","the Elvis Impersonator","the System Administrator", "the Earth Mother","~N's Mentor","the Big Baby", "the One Who Resembles ~W","the One Who Has Seen ~W From Afar", "the Car","the Albatross","the Penguin","the Joker","the Riddler" }; char *whois[] = { /* ~N */ "Aries","Cancer","Gemini","Taurus","Scorpio","Leo","Pisces","Libra", "Aquarius","Virgo","Emperor Chung","Jean Dixon","The Amazing Kreskin", "Soupy Sales","Saturn","Jupiter","Mercury","Chronos","Pluto","Hel", "Mars","Venus","Gaia","Uranus","Chthon","Neptune","Zarkov","Flash Gordon", "Margaret Thatcher","Ronald Reagan","Howdy Doody","Lot O. Droyd", "Obiwan Kenobi","Yoda","Thor","Zeus","Odin","Scooby Doo","Papa Smurf", "Yogi Bear","Regina","Renaldi","Elijawon","Jason","Elvis","Oz", "Glinda","Manitoba","Penacook","Sitting Bull","Sunny Kirsten", "Cheryl","Ray Frank","Ken Arndt","Kral","George ~N Washington", "~N ( ~W ) ~N","He-Man","She-Ra","Cinderella","Prince Charming", "Godzilla","Gamera","King Kong","She-Mommy","Nostradamus","Einstein", "Houdini","My Mother" #ifdef DRI ,"~D","~D","~D","~D","~D","~D","~D","~D", "~D (aka ~N)" }; char *dri[] = { /* ~D */ "Adam Messer","Andrea McDonald","Bill Tyler","Bruce Holloway", "Christina Shaw","Curt Geske","Dan Erickson","Dan Riddel-Kaufman", "Dick Williams","Frank Holsworth","Gary Kildall","Greg Pachner", "Greg Rossi","Gregg Morris","Henri Socha","Jeff Newman","Joe Guzaitas", "Karl (Erick) Braun","Ken Belanger","Larry Towner","Lowell Webster", "Marilyn Bohl","Mark Alexander","Mike Bailey","Mike Franusich", "Mike MacLeod","Nancy Zentner","Peter Bolton","Renate Heisler", "Rob Patten","Robert Bruce","Russ Weiser","Stan McKee","Steve Cavender", "Stephanie Horoszko","Steve Toner","Tony Harris","Wayne Davison" #endif }; char *predicts[] = { /* ~P */ "you have dreamed that ~P. You will have such dreams again", "your nose is oddly formed, and your eyes are of different color", "you have contracted a fatal illness, but your belief in ~N, ~W, will pull you through", "you will donate all your worldy possessions to ~N, ~W. You align yourself correctly for the coming jihad", "your phone will ring soon. It will be someone whom you aren't looking at, or ~W. If the latter, leave a message at the tone", "you will die before you finish reading this prediction, unless ~N smiles on you. If you DO survive, ~W will require a sacrifice before you learn that ~P", "you are not satisfied with life", "you often have fits of depression and feelings of uselessness", "you harbor a secret desire to become ~W. Hide these feelings", "your karma is troubled", "the Force is strong in you", "your phone is not ringing", "you will not die before you finish reading this prediction", "you will take a long trip soon", "you feel you are not living up to your potential", "you are not satisfied with your position", "your situation is improving", "you have contracted a fatal illness and will die", "you will be contacted by aliens within the year. You may not recognize them, though they will give you clear signs", "you will buy something from the Home Shopping Network", "you will win ~$ dollars with LOTTO-DROID. Make obeisance to ~W", "you will change your name three times in the next three years. You will not change it to ~N. Yet, ~W will continue to influence your every move", "people say ~P", "you must shun ~W at all turns. Be vigilant in this", "you must not believe predictions from cheap programs like this one. Look to ~N for clear truth", "your terminal is straining your eyes", "your hair is changing color. Also, ~P", "good fortune awaits you around every corner", "it's not what you do, it's how you do it", "your good fortune is at an end. Look to ~N, ~W, for guidance", "your life has already peaked. You are on a long, downward slide", "you have a brilliant future ahead of you. But rest not; ~P", "you have an ardent desire to add more predictions to this program. Hold that thought, and ~N, ~W, predicts that ~P", "you will be fired for spending so much time playing with a cheap little program like this one" }; char *fullthing[] = { "Listen! ~W has seen that ~P! Prove ~N wrong, and instead, ~P.", "Logout immediately! I, ~N, ~W, have seen that ~P! However, ~P.", "I've heard that ~P. To avoid this fate, buy the seven Books of ~W, and ~N will smile upon you once again, and you will find that ~P.", "Heretic! Listen not to the simpleminded aphorisms of ~N! Only ~N, ~W, can help! Heed this, or I predict that ~P!", "~N, ~W, has said that ~P.", "I have received a psychic message from ~W, who says that ~P. If so, ~N forsees that ~P. This is true. Do not ignore this, or ~N, ~W, will become extremely angry.", "Your biorythm is in turmoil. ~N, ~W, has the answers.", "Other soothsayers tell untruths. ~N has the answers. Worship ~W, and you will find that ~P.", "~N, ~W, knows that ~P. And much more. Send money.", "Bathe in the presence of ~N, and know that ~P.", "Beware, ~W has said that ~P, but ~P.", "\"I predict that ~P\", says ~N, ~W. Listen well, for ~P.", "Know that ~P. All this ~N has seen. Remember, ~W is never wrong. As a token of truth, ~P.", "Run this program again, and find that ~P.", "An urgent message from ~W! Ignore this, and find that ~P. But listen well, and hang a token of ~N, ~W, about your neck, for ~P." }; #define NUME ((sizeof emotion)/sizeof(char *)) #define NUMW ((sizeof whatis)/sizeof(char *)) #define NUMN ((sizeof whois)/sizeof(char *)) #define NUMP ((sizeof predicts)/sizeof(char *)) #define NUMF ((sizeof fullthing)/sizeof(char *)) #ifdef DRI #define NUMD ((sizeof dri)/sizeof(char *)) #endif int col = 0, nump = 3; char token[256]; main(acnt,avar) int acnt; char *avar[]; { int i, f; srandom(time(0L)); if(acnt > 1) nump = atoi(avar[1]); for(i=0; i<nump; ++i){ tokenize(fullthing[rnd(NUMF)]); printf("\n\n"); col = 0; } } int isspace(ch) int ch; { return(ch == ' '); } int rnd(n) int n; { return((random() & 0x7FFF) % n); } tokenize(s) char *s; { char tmptok[256]; char *s1; int l; for(;;){ while(isspace(*s)) ++s; if(!*s) return; for(s1=token; *s && !isspace(*s);) *s1++ = *s++; *s1++ = ' '; *s1 = 0; l = (s1-token); if(l > 1 && token[0] == '~'){ switch(token[1]){ case '$': sprintf(tmptok,"$%d%02d.00",rnd(10000),rnd(100)); break; #ifdef DRI case 'D': strcpy(tmptok,dri[rnd(NUMD)]); break; #endif case 'E': strcpy(tmptok,emotion[rnd(NUME)]); break; case 'W': strcpy(tmptok,whatis[rnd(NUMW)]); break; case 'N': strcpy(tmptok,whois[rnd(NUMN)]); break; case 'P': strcpy(tmptok,predicts[rnd(NUMP)]); break; default: strcpy(tmptok,">>WHOOPS<<"); break; } strcat(tmptok,&token[2]); tokenize(tmptok); continue; } if((col + l) > MAXCOL){ printf("\n"); col = 0; } printf("%s",token); col += l; } }