#include <stdio.h>
int main(void)
{
int i, j;
printf("Enter i: ");
scanf("%d", &i);
printf("Enter j: ");
scanf("%d", &j);
/* relational operations */
printf("i < j %d\n", i < j);
printf("i <= j %d\n", i <= j);
printf("i == j %d\n", i == j);
printf("i > j %d\n", i > j);
printf("i >= j %d\n", i >= j);
/* logical operations */
printf("i && j %d\n", i && j);
printf("i || j %d\n", i || j);
printf("!i !j %d %d\n", !i, !j);
return 0;
}
|