• Pete (unregistered)

    Frits

  • LCrawford (unregistered)

    This is the stuff you get as people are preparing for java.lang.Math.max() being a copyrighted API. It only gets worse if the court sides with Oracle.

  • Divbad (unregistered)

    Surnames are harder!

    https://www.bbc.co.uk/news/world-us-canada-54470427

    ...The other seven face charges of terrorism and gang-related offences in state court in connection with the alleged abduction plot. They are Paul Bellar, Shawn Fix, Eric Molitor, Michael Null, William Null, Pete Musico and Joseph Morrison....

  • (nodebb)

    I used to work at a place that coded damaged items as 0.001 quantity. That way they can look at an inventory report and if it says 209.006 in stock, they have 209 to sell and 6 damaged to return to the vendor (these were pharmaceuticals, you can't just throw them out). The thousandths didn't mess up the inventory valuation enough to matter and the sales interface wouldn't let anyone buy the 0.006.

    Of course, one time we had a recall and marked ten thousand units as damaged and all hell broke loose. We had zero actual stock, but showed ten and the market had almost no supply so there was a buying frenzy. We probably attempted to sell those ten a hundred times.

  • Pip (unregistered)

    Whoa. Transformers and G.I. Joe in the post today. Hello nostalgia!

  • (nodebb) in reply to Jaime

    Yeah, stupid programmers will stupid. I have to fight with folks who want to use a zero to indicate no value found; trying to explain to them that zero in fact might be a valid measurement value is HARD! There's a reason many languages have official "NULL" (yeah, I know...) or "NA" values baked in to their definition of floating-point values.

  • (nodebb) in reply to Pip

    Also Varley should bring nostalgia. Titan was published in 1979.

    Addendum 2020-10-09 09:37: Hooray, markdown! Didn't know that had changed.

  • Angela Anuszewski (google) in reply to Divbad

    Reminded me of an article I once read.

    https://www.wired.com/2015/11/null/

  • (nodebb) in reply to cellocgw

    Yeah, stupid programmers will stupid.

    I was the programmer. The users decided to do this instead of asking for a feature. I brought it up because it might be the explanation behind the 0.9 units in stock from the post.

  • (nodebb) in reply to Jaime

    Could be. That said, this is where you need to look for alternatives, at least for that one time where the damaged items actually do pile up:

    • Define a separate warehouse or storage location for damaged items that isn't available for sale
    • Define separate items (DAMAGED-X = damaged item X), then record that you removed ten thousand X and added ten thousand DAMAGED-X
    • Create a fake customer using your own company name/address and a fake sales order for the damaged goods (remove it right before you record the return to vendor)
  • Valts S. (unregistered)

    To be fair, I did later realize that the 0.50€ deal was a one-day-only special, while the 1.60€ deal was a month (or more) long promotion. So, perhaps it's more of my failure than theirs. Still it looked odd. :)

  • The Slice (unregistered)

    Fortnightly? I assume that's Commonwealth country talk for biweekly?

  • Foo AKA Fooo (unregistered) in reply to Jaime

    So changing the field to float or decimal (I sincerely hope it was integer originally) was so much easier than just adding another field for damaged items?

    Even if it was a user request, it's also our job to talk users out of manifestly stupid ideas. Apart from the disaster you described, I wonder how often users would type 0.01 or 0.0001 instead of 0.001 accidentally.

    PS: The explanation for the 0.9 items in stock is, of course, that the item was 10% off.

  • Worf (unregistered) in reply to Valts S.

    Oh, I see that now. Though, I thought it stranger that you could get a cheeseburger for 0,50 Euro versus 0.50 Euro. Bit of a price difference there. (Some places use , as the decimal separator and . as the digit separator (e.g., 1,000,000.50 is 1.000.000,50). It seems to be written both ways in the image.

  • George (unregistered)

    I'm amazed that nobody's commenting on the ridiculous amount of browser add-ons in the urlbar.

  • (nodebb)

    The cheeseburger deal also makes sense if you can only buy 1 at that price.

  • Neveranull (unregistered)

    This is .9 the reply I was going to

  • MiserableOldGit (unregistered) in reply to Jaime
    Yeah, stupid programmers will stupid. -------------------------- I was the programmer. The users decided to do this instead of asking for a feature. I brought it up because it might be the explanation behind the 0.9 units in stock from the post.

    Yep, been there, done that. Several times.

    If you don't have the information, leave the field without entering anything ... I don't want NA, or a space, or a dot, "I dunno". If you want a drop list or checkbox in front of it to say you do or don't know the contents of the box, I'll do that, but FFS, entering random shit data only means you get shit results.

  • Conradus (unregistered) in reply to Divbad

    That's also being reported in other news sources. Apparently, their name really is "Null".

  • (nodebb)

    My local pizza place has, among their current specials for pickup, one offer code allowing you to get any Value, Traditional, or Premium pizza for $12, and another offer code allowing you to get any Traditional or Premium pizza for $10.

    Value pizzas are $5 anyway so it's pointless to include them in the first offer. And their app does do the right thing in not applying an offer that increases the price. Both offers have the same duration.

    I went to show this to my wife and she couldn't really understand what was wrong with it.

  • MiserableOldGit (unregistered) in reply to Scarlet_Manuka

    I worked (as a freelancer) in a place that used to give its employees a loyalty bonus in the form of discounted call options, in other words, they got given a contract that would let them buy a set number of shares at 20% less than today's price, but they couldn't use it for 6 months ... at which point they could keep or sell the shares for their price then.

    When I pitched up, there had been a fuss because the share price had dropped below the discount they'd been given so the company had agreed to reissue the contracts discounted against the latest price. Only in the three weeks it took them to announce this and actually do it, the share price crashed still further so when the employees got these documents the company was offering to sell them its own shares at a higher price than they could get on the open market.

    I did try to explain this to the employees around me who were all excited to get their new certificates ... They didn't get it, with an argument mostly revolving around "but they've given us some shares!". I will say, the one who was arguing with me the most was the only one of the permies who could actually code without a freelance consultant to hold his hand. He handed his notice in a couple of weeks later, so maybe what I said had him do some research. The whole place went down the tubes about 2 months later.

Leave a comment on “Math is HARD!”

Log In or post as a guest

Replying to comment #:

« Return to Article