“Sometimes it is the people no one can imagine anything of who do the things no one can imagine.” ― Sir Alan Turing


ADS

ADS

Saturday, April 8, 2017

UVa 11172 - Relational Operators || Solution in C / C++



Source Code 

#include<stdio.h>

int main() {
  int a, b, c, i;
  while (scanf("%d", & a) == 1) {
    for (i = 0; i < a; i++) {
      scanf("%d%d", & b, & c);
      if (b > c)
        printf(">\n");
      else if (b < c)
        printf("<\n");
      else
        printf("=\n");
    }
  }
  return 0;
}

No comments:

Post a Comment