Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

4
  • 1
    Instead of using raw integer values, you could use objects with overloaded arithmetic operators that throw exceptions when overflow occurs. Commented Jun 2, 2012 at 19:54
  • 2
    what is the operation that you are doing on the numbers? Commented Jun 2, 2012 at 19:55
  • @Baget could be anything. addition, subtraction, multiplication, exponent, so on. depends on the program. Commented Jun 2, 2012 at 19:56
  • 2
    In Assembler you could access the overflow bit of your CPU, but that would of course be platform dependent. Commented Jun 2, 2012 at 19:58