Write say 20 digits down on paper and another 20 or so digits.
Now add them.
Do the same in your compurter program but use arrays and for loops and so on.
Happy computing
ddanbe
Senior Poster
3,829 posts since Oct 2008
Reputation Points: 2,070
Solved Threads: 661
>how can i consider each cases ?
By understanding them. If you don't understand what's going on then you clearly can't tell the computer how to do it. If you do understand what's going on, you can make such connections as realizing that -25-(-30) is actually the same as -25+30, you can move toward the sign of the second operand, and that the difference between negative and positive is the same as setting a flag and reversing direction when you hit 0.
Beyond that it's the same old basic arithmetic that you learned in the first grade.
Narue
Bad Cop
15,460 posts since Sep 2004
Reputation Points: 6,464
Solved Threads: 1,401
> Beyond that it's the same old basic arithmetic that you learned in the first grade.
Do they still teach that?
Apparently not
http://www.literacytrust.org.uk/Database/businessupdate.html
The CBI surveyed more than 500 companies with 1.1million employees. They found that 52% of employers are dissatisfied with the basic literacy of school leavers and 50% with their basic numeracy, but 92% are satisfied with their IT skills. Half of employers said some teenagers were ‘unable to function in the workplace’ claiming they cannot make simple calculations in their heads, speak in an articulate manner or understand written instructions.
What's 92% measuring?
"Has the ability to switch the machine on, and move the mouse without strangling themselves with the cord".
Salem
Posting Sage
11,531 posts since Dec 2005
Reputation Points: 5,862
Solved Threads: 953