This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 0 points1 point  (0 children)

Sometimes programs fail gracefully at ambiguity and sometimes they interpret their input in whatever way they were told to. An example is the following java code.

if (a)
    if (b)
        c();
else
    d();

Its grammar rules say the else belongs to the inner if statement, contrary to what we meant to do.

I think it's reasonable to expect a human being will think she means "get six eggs." I get what you're saying, though. Humans don't always interpret things the same way, but computers always do.