Ad

Friday, March 15, 2013

Uva 11172 - Relational Operators

This is a problem from UVa Online Judge.
Problem ID - 11172,
Problem Name - Relational Operators.

http://uva.onlinejudge.org/index.php?option=onlinejudge&page=show_problem&problem=2113


#include <stdio.h>

main()
{

    int i,a,b,j=1;
    scanf("%d", &i);

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

0 comments:

Post a Comment