CF2009A Minimize!
题目描述
给你两个整数 $a$ 和 $b$ ($a≤b$) 。
在 $c$ ($a≤c≤b$) 的所有可能整数值中,求 $(c−a)+(b−c)$ 的最小值。
输入格式
第一行包含 $t$ ($1≤t≤55$) -测试用例数。
每个测试用例包含两个整数 $a$ 和 $b$ ($1≤a≤b≤10$) 。
输出格式
对于每个测试用例,另起一行输出 $(c−a)+(b−c)$ 的最小可能值。
说明/提示
In the first test case, you can choose $ c = 1 $ and obtain an answer of $ (1 - 1) + (2 - 1) = 1 $ . It can be shown this is the minimum value possible.
In the second test case, you can choose $ c = 6 $ and obtain an answer of $ (6 - 3) + (10 - 6) = 7 $ . It can be shown this is the minimum value possible.