# A. A+B (Trial Problem) Codeforces Solution Kotlin Heroes: Practice 7

Page Contents

## A. A+B (Trial Problem) Codeforces Solution

You are given two integers a and b. Print a+b.

Input
The first line contains an integer t (1≤t≤104) — the number of test cases in the input. Then t test cases follow.

Each test case is given as a line of two integers a and b (−1000≤a,b≤1000).

Output
Print t integers — the required numbers a+b.

Example
input
4
1 5
314 15
-99 99
123 987

output
6
329
0
1110

## Solution

Program C++: A+B (Trial Problem) Solution in C++

```#include <stdio.h>
int main(){
int t,a,b;
scanf("%d",&t);
while(t--){
scanf("%d%d",&a,&b);
printf("%d\n",a+b);
}
return 0;
﻿```

Program Python: A+B (Trial Problem) Solution in Python

```for _ in range(int(input())):
a,b=map(int,input().split())
print(a+b)```

## Codechef Long Challenge Solutions

### 2 thoughts on “A. A+B (Trial Problem) Codeforces Solution Kotlin Heroes: Practice 7”

1. Can anyone share a+b(trial problem) solution in python???