UVa 10035

From Algorithmist
Jump to navigation Jump to search

10035 - Primary Arithmetic[edit]

Summary[edit]

Add the two numbers and count the number of carries that happened.

Explanation[edit]

Just add digit by digit, and count the number of carries.

Gotchas[edit]

  • Watch the spelling. For 0 we have to print "No carry operation.", even though that's not proper grammar.

Input[edit]

123 456
555 555
123 594
0 0

Output[edit]

No carry operation.
3 carry operations.
1 carry operation.