On Mon, 7 Jul 2008 20:26:50 +0000, Chip Davis <[EMAIL PROTECTED]> wrote:
>In fairness, your problem is not caused by unfamiliarity with formal
>logic, but mere lack of clarity.
Brings back memories of the obfuscated C contest. Some of those entries
were brilliant.
>If I might suggest an alternative so far overlooked:
And here is another (obscure) alternative that also allows phrases and
synonyms without complicated logic tests:
/* */
_.=''
_.y='Y'
_.ye='Y'
_.yes='Y'
_.okay='Y'
_.please='Y'
_.maybe='Help'
phrase='I GROVEL BEFORE YOU TO PERMIT IT'
_.phrase='Y'
phrase='YOU ARE CRAZY IF YOU THINK I WANT TO DO THAT'
_.phrase='N'
say 'Should I do this?'
pull answer
SELECT
WHEN _.answer='Y'
THEN say 'I will do it'
WHEN _.answer='N'
THEN say 'I will not do it'
WHEN _.answer='Help'
THEN say 'RTFM and make up your mind'
OTHERWISE say 'Invalid answer'
END
Brian Nielsen