COMBAPOW - GO POKEMON GO!
Pokemon GO! has gotten viral and people of all ages have started playing it. G33K a chemistry professor have also started playing the game, he got his first Pokemon "charmander" but he is a bit confused of his Pokemon's combat power, in professor's mobile the combat power is represented by 4 distinct integers separated by space i1,j1,i2,j2 and a formula is being given which calculates the final combat power of Pokemon!
The formula goes like this -
Since G33k is a chemistry professor he is weak in programming , your task is to calculate the combat power for the professor!
Input
The problem will consist of t test cases, each containing four numbers
t <= 100
4 integers separated by space i1, j1, i2, j2
1 <= i1, j1, i2, j2 <= 100000
i1 < j1, i2 < j2
Output
print the combat power of Pokemon in a new line!
Example
Input: 1 2 3 4 5 Output: 16
hide comments
Francky:
2016-07-22 22:46:51
@Sushovan Sen : it seems to be the very first problem of psetter.
|
|
Sushovan Sen:
2016-07-22 21:30:48
It is better if you increase number of test cases/range and give some proper time limit.
|
|
Bhuvnesh Jain:
2016-07-22 10:28:51
@author, why did you disqualify by submission? Any specific reason.
|
Added by: | surayans tiwari |
Date: | 2016-07-21 |
Time limit: | 0.100s |
Source limit: | 50000B |
Memory limit: | 1536MB |
Cluster: | Cube (Intel G860) |
Languages: | All except: MAWK BC NCSHARP COFFEE DART FORTH GOSU JULIA KTLN OCT PROLOG PYPY3 R RACKET SQLITE SWIFT UNLAMBDA |
Resource: | self |