Practice on Toph

Participate in exhilarating programming contests, solve unique algorithm and data structure challenges and be a part of an awesome community.

Genius Needs Help

By Farhan_meb · Limits 1s, 256 MB

You all know Emrul bhai, right? He is a genius guy. He knows how to add two integer numbers and so do you.

  56        
 +25   
----
  81     

He has a crush and her facebook name is “Sweety girl Jorina”. One day Emrul bhai’s friend Rafat bhai challenged him if his juinors from first year can make a program that adds two very large numbers, then they will make a meeting for him with his crush.

Now Emrul bhai came running to you sweating and asked “Can you please do it for me so that I can meet my sweety girl?”.

Input

You will be given a test case T (1 ≤ 100 ≤ T). In each case, you will be given two numbers A and B (0 ≤ Digits in A and B ≤ 105).

Output

For each case, you have to print the case number and the summation of the given numbers.

Samples

InputOutput
2
123 123
3333311111111111 44422222221111
Case #1: 246
Case #2: 3377733333332222
InputOutput
3
9 0
111 45666664777412335425321458777
47895445222125456544456 4565429875595631
Case #1: 9
Case #2: 45666664777412335425321458888
Case #3: 47895449787555332140087

Number A and B can be very large.

You can’t store in int or long long int data type if digits number in a number is greater than 18. You have to store it in a string.

It is guaranteed that summation of A and B won’t contain leading zero’s.


Discussion
Statistics

77% Solution Ratio

shojib_muEarliest, 4M ago

GeraltFastest, 0.0s

Valentin_ELightest, 10 MB

Valentin_EShortest, 489B

Submit

Login to submit