UVa 11172 Relational Operator (water ver.)
2013-09-21 10:30
866 查看
11172 - Relational Operator
Time limit: 3.000 secondshttp://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=24&page=show_problem&problem=2113
Some operators checks about the relationship between two values and these operators are called relational operators. Given two numerical values your job is just to find out the relationship between them that is (i) First one is greater than the second (ii)
First one is less than the second or (iii) First and second one is equal.
Input
First line of the input file is an integer t (t<15) which denotes how many sets of inputs are there. Each of the next t lines contain two integers a and b (|a|,|b|<1000000001).
Output
For each line of input produce one line of output. This line contains any one of the relational operators “>”, “<” or “=”, which indicates the relation that is appropriate for the given two numbers.Sample Input Output for Sample Input
3 10 20 20 10 10 10 | < > = |
/*0.015s*/ #include<cstdio> int main(void) { int t, a, b; scanf("%d", &t); while (t--) { scanf("%d%d", &a, &b); puts(a < b ? "<" : (a == b ? "=" : ">")); } }
相关文章推荐
- UVa 11150 Cola (water ver.)
- UVa 414 Machined Surfaces (water ver.)
- UVa 445 Marvelous Mazes (water ver.)
- UVa 10346 Peter's Smokes (water ver.)
- UVa 575 / ZOJ 1712 / Mid-Central USA 1997 Skew Binary (water ver.&斜二进制)
- UVa 11340 Newspaper (water ver.)
- UVa 10252 Common Permutation (water ver.)
- UVa 102 Ecological Bin Packing (water ver.)
- UVa 10008 What's Cryptanalysis? (water ver.)
- UVa 11371 Number Theory for Newbies (water ver.)
- UVa 272 TEX Quotes (water ver.)
- UVa 10696 f91 (water ver.)
- UVa 12640 Largest Sum Game (water ver.)
- UVa 621 Secret Research (water ver.)
- UVa 11498 Division of Nlogonia (water ver.)
- UVa 371 Ackermann Functions (water ver.)
- UVa 488 Triangle Wave (water ver.)
- UVa 11727 Cost Cutting (water ver.)
- UVa 10656 Maximum Sum (II) (water ver.)
- UVa 11547 Automatic Answer (water ver.)