Problem1465--Sum of integers - easy

1465: Sum of integers - easy

Time Limit: 1 Sec  Memory Limit: 128 MB
Submit: 18  Solved: 10
[Submit] [Status] [Web Board] [Creator:]

Description

Write a program that finds the sum of all integers from n to m when n and m are given.

Input

The number of test cases T is entered. 
Then, n and m of each test case are entered line by line. (-105 <= n<= m <= 105)

Output

Print the sum of all integers from n to m.

Sample Input Copy

2
1 100
-11 10

Sample Output Copy

5050
-11

Source/Category