• Mark (unregistered)

    FIRST

  • Molt (unregistered) in reply to Mark

    Bah, you could have at least said "FIRST OF INFINITY!"

  • facilisi (unregistered)

    Hey Joe, I never get SPAM about my gay issues, so what kind of sites have you been visiting anyway?

  • airdrummer (unregistered)

    mebbe that explains the current banking crisis;-)

  • (cs) in reply to Mark

    In Monty's case, I suspect the system was explaining that any amount you withdraw must be divisable by your current balance!

  • (cs)

    printf("I bet 90% of you won't get the spam WTF.");

  • (cs)

    Why is Bruce paralyzed with uncertainty? He doesn't even have a choice.

  • Ryuzaki (unregistered) in reply to Smash King

    Perhaps he's really paralyzed with certainty. He has no other options.

    /divides by zero and hits the deck

  • phrawzty (unregistered)

    What game is that a screenshot from ?

  • (cs) in reply to phrawzty

    That's from EVE online... I'm not really suprised, EVE devs are famous for these kind of error messages.

  • Stephen Eilert (unregistered) in reply to phrawzty

    Eve Online.

  • jakub (unregistered) in reply to phrawzty
    phrawzty:
    What game is that a screenshot from ?

    EVE online, I think

  • (cs) in reply to phrawzty
    phrawzty:
    What game is that a screenshot from ?

    EVE Online. Apparently.

  • KO (unregistered)

    I think its from EVE ONline!

  • JimmyVile (unregistered) in reply to phrawzty
    phrawzty:
    What game is that a screenshot from ?
    EVE Online
  • Kuli (unregistered)

    Ah, now I know that it's EVE Online. Whatever this is.

    Alas Maren didn't tell us what happened after she requested more information...

  • Mr^B (unregistered) in reply to phrawzty
    phrawzty:
    What game is that a screenshot from ?

    It's the hidden level from Hello Kitty Island Adventure.

  • Eric L (unregistered)

    Apparently Monty forgot they "ain't so good at math" there in Alabama

  • (cs)

    It's from Madden 2005.

  • Kalleguld (unregistered) in reply to ParkinT
    In Monty's case, I suspect the system was explaining that any amount you withdraw must be divisable by your current balance!
    So he's only allowed to withdraw his whole balance, or multiples thereof?

    My theory is that the ATM is out of cash (or really low on all the different bills), and that led to an error in the loop that sets the lowest amount cashable.

    Or maybe a bank teller had just refilled the stock of 0$ bills

  • rd (unregistered)

    I'm not really sure, but I think it's EVE Online. Maybe someone else can verify.

  • (cs) in reply to rd

    Jump to Comment Infinity of Infinity

  • Adriano (unregistered) in reply to Molt
    Molt:
    Bah, you could have at least said "FIRST OF INFINITY!"
    That's what it says on the first page: "Page 1 of Infinity".
  • (cs)

    Just a whit of wit?

  • Anonymouse (unregistered)

    Has anyone said it's from EVE Online yet?

  • (cs) in reply to rd
    rd:
    I'm not really sure, but I think it's EVE Online. Maybe someone else can verify.

    You're right, yes. It's EVE Online. I'm surprised nobody else knows that. It's a pretty popular game.

  • (cs) in reply to rd
    rd:
    I'm not really sure, but I think it's EVE Online. Maybe someone else can verify.

    Congrats, you are the seventh person to point out this game. Yes, the screenshot is from EVE Online during a portion where a player is in a hangar, talking to an agent, and getting breifed on a mission. The game is riddled with Goons so don't bother playing unless you want to be raped by a bunch of drunken Irish, Scottish, and British men with nothing better to do but be ass pirates.

  • (cs) in reply to SlyEcho
    SlyEcho:
    printf("I bet 90% of you won't get the spam WTF.");
    It's a format string vulnerability in the ratware; it's taken a %g floating point conversion from what is supposedly the spam template (which often use %-specifiers for their hashbuster, mailmerge and other variable parts of the spam).

    Now, all we need to do is

    1. Figure out which spamware was in use and get a copy
    2. Write an exploit that looks like a piece of spam mail
    3. Hire a spammer to mass mail our "latest marketing campaign".
    4. ????
    5. Profi... err I mean PWN4G3!
  • (cs) in reply to LightStyx
    LightStyx:
    rd:
    I'm not really sure, but I think it's EVE Online. Maybe someone else can verify.
    Congrats, you are the seventh person to point out this game.
    OH, HAI, I IZ FIXIN' UR SARKAZM DETEKTOR

    KTHXBAI

  • (cs) in reply to Kalleguld
    Kalleguld:
    In Monty's case, I suspect the system was explaining that any amount you withdraw must be divisable by your current balance!
    So he's only allowed to withdraw his whole balance, or multiples thereof?
    The OP is really random here. Even the other way up, that division wouldn't make any sense; why would a bank want you to only be able to withdraw 1/N.th of your money (for any N > 0) and not any other fraction?

    Hint to OP: It needs to be "smaller than", not "divisable(sic) by".

    Kalleguld:
    My theory is that the ATM is out of cash (or really low on all the different bills), and that led to an error in the loop that sets the lowest amount cashable.
    Your theory pretty much wins hands down. I'm guessing that zero is "the size of the smallest bill which the ATM has any left of" - i.e. it's completely empty.
    Kalleguld:
    Or maybe a bank teller had just refilled the stock of 0$ bills
    Zero-dollar bills? I'm sure we did this one before....
  • (cs) in reply to DaveK
    DaveK:
    Kalleguld:
    My theory is that the ATM is out of cash (or really low on all the different bills), and that led to an error in the loop that sets the lowest amount cashable.
    Your theory pretty much wins hands down. I'm guessing that zero is "the size of the smallest bill which the ATM has any left of" - i.e. it's completely empty.
    Of course, that doesn't really help, because any number is divisible by zero (the result is undefined, but the number itself is divisible by zero), or indeed any other number (For instance, 38.53 is divisible by 10).

    Clearly, the screen should read "Amount Entered must give an exact integer result when divided by:", which is both clear and comprehensive.

  • (cs)

    There is an EASY way to prevent divide by zero errors, so easy that I am surprised they haven't built it into the .NET framework yet... Simply add 0.000000001 to the denominator. This is such a small number that it makes no significant difference to the result. I like to make a constant, something like this and it works like a champ...

    Const NODBZ As Double = 0.000000001 ...

    X = Y / (Z + NODBZ)

    Then just round it when you are done.

  • Old Coder (unregistered) in reply to JimM
    JimM:
    Clearly, the screen should read "Amount Entered must give an exact integer result when divided by:", which is both clear and comprehensive.

    ...and which statement only four people in the state will understand.

  • Michael (unregistered)

    Nullity is the Real WTF.

  • anonymous_coder() (unregistered) in reply to LightStyx
    LightStyx:
    rd:
    I'm not really sure, but I think it's EVE Online. Maybe someone else can verify.

    Congrats, you are the seventh person to point out this game. Yes, the screenshot is from EVE Online during a portion where a player is in a hangar, talking to an agent, and getting breifed on a mission. The game is riddled with Goons so don't bother playing unless you want to be raped by a bunch of drunken Irish, Scottish, and British men with nothing better to do but be ass pirates.

    EVE - 'Where geeks get to be bullies'. Great game for PvP, but anything else is boring or impossible.

  • Old Coder (unregistered) in reply to TopCod3r
    TopCod3r:
    There is an EASY way to prevent divide by zero errors, so easy that I am surprised they haven't built it into the .NET framework yet... Simply add 0.000000001 to the denominator. This is such a small number that it makes no significant difference to the result. I like to make a constant, something like this and it works like a champ...

    Const NODBZ As Double = 0.000000001 ...

    X = Y / (Z + NODBZ)

    Then just round it when you are done.

    Riiiight. So, just divide by a very very small number, and your result turns out to be a very very large number, which might cause an overflow exception instead. Very useful.

    Or perhaps, you know, the divide-by-zero exception flags up the fact that there is a bug in the algorithm, and your little add-on just hid it?

  • Teller (unregistered) in reply to ParkinT
    ParkinT:
    In Monty's case, I suspect the system was explaining that any amount you withdraw must be divisable by your current balance!
    In which case the ATM's user interface could (and probably should) be simplified:

    "How many times your current balance would you like to withdraw? Please press 1, 2 or 3."

  • Dascandy (unregistered) in reply to Kalleguld

    If it really is out of bills, it's the most sane and mathematically correct answer to give, assuming that the person withdrawing money is also mathematically minded.

  • /b Zap Brannigan b/ (Deleted as Troll) (unregistered) in reply to Old Coder
    Old Coder:
    JimM:
    Clearly, the screen should read "Amount Entered must give an exact integer result when divided by:", which is both clear and comprehensive.

    ...and which statement only four people in the state will understand.

    Yes that message would only make sense in the Eurpean version. The US message should be something like: You got no money fool! Would you like to apply for credit Y/N?

  • Daedalus (unregistered) in reply to JimM
    JimM:
    DaveK:
    Kalleguld:
    My theory is that the ATM is out of cash (or really low on all the different bills), and that led to an error in the loop that sets the lowest amount cashable.
    Your theory pretty much wins hands down. I'm guessing that zero is "the size of the smallest bill which the ATM has any left of" - i.e. it's completely empty.
    Of course, that doesn't really help, because any number is divisible by zero (the result is undefined, but the number itself is divisible by zero), or indeed any other number (For instance, 38.53 is divisible by 10).

    Clearly, the screen should read "Amount Entered must give an exact integer result when divided by:", which is both clear and comprehensive.

    Whut. No. NO. There are two ways to interpret "a is divisible by b":

    1. (The way EVERYONE does it) a/b is an integer. b is often an integer, but this is not necessary (i.e., 4.5 is divisible by 1.5 but not by 1)
    2. (Your own special way) a/b is defined. In other words, b!=0 Neither of these defends having a number be divisible by zero. How can you claim 4 is divisible by 0, if 4/0 is undefined?
  • Dascandy (unregistered) in reply to TopCod3r

    That's impressively stupid.

    Suppose that Y is 1E-20 and Z is also 1E-20. You've just introduced a factor 100,000,000,000 error in the result.

    Suppose that Y is -1E-9 and Z is also -1E-9. That should just be 1, but thanks to you it's a divide by zero!

  • (cs) in reply to Old Coder
    Old Coder:
    TopCod3r:
    There is an EASY way to prevent divide by zero errors, so easy that I am surprised they haven't built it into the .NET framework yet... Simply add 0.000000001 to the denominator. This is such a small number that it makes no significant difference to the result. I like to make a constant, something like this and it works like a champ...

    Const NODBZ As Double = 0.000000001 ...

    X = Y / (Z + NODBZ)

    Then just round it when you are done.

    Riiiight. So, just divide by a very very small number, and your result turns out to be a very very large number, which might cause an overflow exception instead. Very useful.

    Or perhaps, you know, the divide-by-zero exception flags up the fact that there is a bug in the algorithm, and your little add-on just hid it?

    Ever heard of Try/Catch?

    I should have clarified, this solution is for Integers... it becomes a decimal when you add 0.000000001 to it, that is why I said you have to round it back.

  • SS (unregistered) in reply to Teller

    I swear to God I'm going to pistol whip the next guy who says, "EVE Online."

  • Zap Brannigan (unregistered) in reply to Old Coder
    Old Coder:
    TopCod3r:
    There is an EASY way to prevent divide by zero errors, so easy that I am surprised they haven't built it into the .NET framework yet... Simply add 0.000000001 to the denominator. This is such a small number that it makes no significant difference to the result. I like to make a constant, something like this and it works like a champ...

    Const NODBZ As Double = 0.000000001 ...

    X = Y / (Z + NODBZ)

    Then just round it when you are done.

    Riiiight. So, just divide by a very very small number, and your result turns out to be a very very large number, which might cause an overflow exception instead. Very useful.

    Or perhaps, you know, the divide-by-zero exception flags up the fact that there is a bug in the algorithm, and your little add-on just hid it?

    I know I'm replying to TopCod3r, but I have actually used this technique. If someone has a better solution, I'm listening.

  • Daedalus (unregistered) in reply to /b Zap Brannigan b/ (Deleted as Troll)
    /b Zap Brannigan b/ (Deleted as Troll):
    Old Coder:
    JimM:
    Clearly, the screen should read "Amount Entered must give an exact integer result when divided by:", which is both clear and comprehensive.

    ...and which statement only four people in the state will understand.

    Yes that message would only make sense in the Eurpean version. The US message should be something like: You got no money fool! Would you like to apply for credit Y/N?
    When making snide comments about how idiotic Americans are, try to at least spell correctly. Although "Eurpean" is a funny word. CAPTCHA: populus

  • EatenByAGrue (unregistered)

    It's not "100 2.04858e+290 growth", it's "100 2.04858e+290rowth".

    I'm not sure what rowth is, but I still don't want 2.04858e+290 of it.

  • EVE Online (unregistered)

    EVE Online

    (captcha: EVE Online)

  • (cs) in reply to TopCod3r
    TopCod3r:
    There is an EASY way to prevent divide by zero errors, so easy that I am surprised they haven't built it into the .NET framework yet... Simply add 0.000000001 to the denominator. This is such a small number that it makes no significant difference to the result. I like to make a constant, something like this and it works like a champ...

    Const NODBZ As Double = 0.000000001 ...

    X = Y / (Z + NODBZ)

    Then just round it when you are done.

    Very smart idea actually. So let me try to divide by Z = -0.000000001 Oops.

  • Teller (unregistered) in reply to Old Coder
    Old Coder:
    JimM:
    Clearly, the screen should read "Amount Entered must give an exact integer result when divided by:", which is both clear and comprehensive.
    ...and which statement only four people in the state will understand.
    ... and which statement still gets us nowhere if the ATM is trying to tell us that the amount entered must give an exact integer result when divided by $0.00.
  • Jetts (unregistered) in reply to SS
    SS:
    I swear to God I'm going to pistol whip the next guy who says, "EVE Online."

    Hey Farva, whats the name of that online game you like to play? You know the MMORPG with the space ships?

Leave a comment on “Unprepared For Divide_By_Zero”

Log In or post as a guest

Replying to comment #:

« Return to Article