summaryrefslogtreecommitdiff
path: root/compare.c
blob: 6c436bf8dda07702919f0411268eed8ce1680bb4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#include <stdio.h>
#include <cs50.h>

int main(void)
{
int x = get_int("What's x? ");
int y = get_int("What's y? ");

if (x < y)
{
    printf("x is less than y\n");
}
else if (x > y)
{
    printf("x is greater than y\n");
}
else
{
    printf("x is equal to y\n");
}
}