A Subtracting Problem

View as PDF

Submit solution

Points: 3
Time limit: 1.0s
Memory limit: 64M

Problem type

You are given \(Q\) queries of the form:

  • a b \((-10^9 \le a,b \le 10^9)\). This query asks for \(a-b\) if \(a < b\), and \(b-a\) if \(b \le a\).

For each query, print out the desired answer!

Input Specification

The first line will contain the integer \(Q\ (1 \le Q \le 10^5)\).

The next \(Q\) lines will each contain a query of the form defined above.

Output Specification

For each query, print the desired answer on its own line.

Sample Input

1 3
3 2
10 29

Sample Output



There are no comments at the moment.