Saturday, November 13, 2021

Add Two Numbers | Problem Code: FLOW001 || Codechef Solution

 


Add Two Numbers | Problem Code: FLOW001

Shivam is the youngest programmer in the world, he is just 12 years old. Shivam is learning programming and today he is writing his first program.
The program is very simple, given two integers A and B, write a program to add these two numbers.

 

Input

The first line contains an integer T, the total number of test cases. Then follow T lines, each line contains two integers A and B.

 

Output

For each test case, add A and B and display them in a new line.

 

Constraints

  •  T  1000
  •  A, B  10000

 

Example

Input
3 
1 2
100 200
10 40

Output
3
300
50
#include<iostream>
using namespace std;
int main() {
   int T;
   cin>>T;
   int a[T];
   for(int i=0;i<T;i++) {
      int a,b;
      cin>>a>>b;
      cout<<a+b<<endl;
      }
   }

No comments:

Post a Comment