Hacker News new | ask | show | jobs
by T-hawk 4899 days ago

  cart.addJugs(1);
  if (haveEggs)
    cart.addJugs(12);
Now the cart has 13 jugs.
1 comments

I'd say that "get a dozen" implies "jugs = 12" and not "jugs += 12". If you wanted to get a dozen more, you'd say "get a dozen more"
This is why we don't program in English.
And why it is so hard to write a good specification.
"get a dozen" implies "jugs += 12"