EXPLICATION OF WHAT TANIMOTO'S SHRINK (ELIZA LOOK-ALIKE) PROGRAM DOES. set wwordcount <-- 0 ;used to randomize "wword" chosen below set puntcount <-- 0 say "welcome to my sofa" say "Please enclose your input in parentheses" start a loop here get the next line of the user's input map the "me" words to "you" words and vice versa -- e.g. i love you --> you love me store the resulting text in the variable called S if S=(bye) then write goodbye and quit Now "fire" the first rule below that applies and then return to the line labelled "start a loop here" above if S has the form "you are X" then pick a 'wword' among one of the words "when, why, or where, and then say "please tell me wword you are X". -- e.g. if the patient says "I am so sick of waking up with a hangover!" then the Shrink says "Please tell me why you are so sick of waking up with a hangover." if S has the form "you have X" then say "How long have you had X?" if S has the form "you feel X" then say "I sometimes feel the same way." if S has the form "Because X" then say "Is that really the reason?", if S is an empty line of text then say "Please say something." if S has the form "Yes X" then say "How can you be so sure X?" if S has the form "Me are X" then say "Oh yeah I am X." if S has the form "Verb X" (e.g. drop dead) then say "Oy yoi he wants that I should go and Verb X" if S has the form "Wpred X" where Wpred is "why", "where", "when", or "what" then say "You tell me Wpred." if S has the form "Dpred Me X" where Dpred is "do", "can", "should", or "would" then say "Perhaps I Dpred X". -- e.g. "would you lie?" would result in "perhaps I would lie." if S has the form "Do me think X" then say "I think you should answer that yourself.". if S contains the word "dream" then say "For dream analysis, see Freud." if S contains the word "love" then say "All is fair in love and war." if S contains the word "no" then say "Don't be so negative." if S contains the word "maybe" then say "Be more decisive." if S contains the word "you" then say S. OTHERWISE add 1 to the puntcount, and use the number to choose and print the next punt. PUNTS: 0. Please go on. 1. Tell me more. 2. I see. 3. What does that indicate? 4. But why be concerned about it? 5. Just tell me how you feel.