While you make a good point about it being much more difficult for programs to catch the DIV0, it's also hard to get a human to correctly write a response to it.<br><br>Mathematically, 1/0 is meaningless. The best you can get is by taking limits to get answers like "does not exist" or "infinite", but you couldn't expect humans to answer that any better without a disclaimer (which could then, feasibly, be picked up by a program as well).
<br><br>Sure, it could be done, but is it worth it? Maybe.<br><br>I do agree though -- my catpcha are sad -- but it'd be very much possible to write some more difficult ones. The deck one was a halfhearted attempt at such and is hardly the upper limit. I tried to make sure this was very easy to do, but didn't focus on actually doing it. My bad.
<br><br>All that being said, I'm not going to defend my code too much. It's very simplistic and I'm not good enough to push it too far past that within a reasonable amount of time. However, I'd love to see a more complete answer.
<br><br><div><span class="gmail_quote">On 5/3/06, <b class="gmail_sendername">Pascal Bourguignon</b> <<a href="mailto:pjb@informatimago.com">pjb@informatimago.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Tel writes:<br>> (defvar *query-strings* '((* "what is ~r times ~r?"<br>> (gennumber gennumber))<br>> (* "what is the product of ~r and ~r?"<br>
> (gennumber gennumber))<br>> (* "what is the area of a ~r by ~r rectangle?"<br>> (gennumber gennumber))<br>> (* "If you have ~r card~:p in a deck, then give the deck away,
<br>> how many cards do you have?~*"<br>> (gennumber 0))<br>> (+ "what is ~r plus ~r?"<br>> (gennumber gennumber))<br>> (+ "what is the sum of ~r, ~r, and ~r?"
<br>> (gennumber gennumber gennumber))<br>> (+ "if you have ~r apricot~:p and buy ~r more, how many do you have?"<br>> (gennumber gennumber))
<br>> (- "what is ~r less ~r?"<br>> (gennumber gennumber))<br>> (- "what is the difference between ~r and ~r?"<br>> (gennumber gennumber))
<br>> (- "if you have ~r dollar~:p but owe ~r, you effectively have how many?"<br>> (gennumber gennumber))<br>> (/ "what is ~r over ~r?"
<br>> (gennumber gennumber))<br>> (/ "what is the quotient of ~r and ~r"<br>> (gennumber gennumber))<br>> (/ "if you could split ~r watch~:*~[es~;~:;es~] into ~r equal
<br>> group~:p, how many are in each group?"<br>> (gennumber gennumber))))<br><br>Really guys, these are no captcha. Have a look at the student program<br>in PAIP (<a href="http://norvig.com">
norvig.com</a>). It could easily solve these kind of problems,<br>with very little or no added rules and code.<br><br><br>Why remove the division by 0? On the contrary, this is something that<br>could discriminate between a human and an computer, more than "what's
<br>the difference between three and two". Even if some human would<br>answer: EDIV0.<br><br><br>--<br>__Pascal Bourguignon__ <a href="http://www.informatimago.com/">http://www.informatimago.com/
</a><br><br>Pour moi, la grande question n'a jamais été: «Qui suis-je? Où vais-je?»<br>comme l'a formulé si adroitement notre ami Pascal, mais plutôt:<br>«Comment vais-je m'en tirer?» -- Jean Yanne<br></blockquote></div><br>
<br clear="all"><br>-- <br>~ja.<br>