A Plus B
Submit solution
C++, Java, Python
Points:
100
Time limit:
2.0s
Memory limit:
64M
Author:
Problem type
Allowed languages
Problem Statement
Yara likes math but does not want to spend time solving the same type of math problems.
Her math teacher gave her an assignment with 3 addition problems. Help Yara create a program to solve these problems quickly.
You will get 3 addition questions. In each question there will be 2 numbers A
and B
. Add the two numbers and display the output to Yara.
Constraints
A
andB
values are integers between -100 and 100- You will need to perform 3 additions per test case
Input
Input is in the following format:
A1
B1
A2
B2
A3
B3
A1, B1 are for the first addition. A2, B2 are for the second addition. A3, B3 are for the third addition. All inputs to be captured first then processed.
Output
Print result of all additions like so (where C is the addition result):
C1
C2
C3
Samples
Sample 1
Input | Output |
---|---|
1 2 -5 2 10 10 |
3 -3 20 |
Sample 2
Input | Output |
---|---|
-1 -50 100 -100 33 20 |
-51 0 53 |
Sample 3
Input | Output |
---|---|
98 -8 7 7 15 22 |
90 14 37 |
Comments