IF statement 3
#include <stdio.h>
main() {
int i,j,big; //variable
scanf("%d%d",&i,&j);
big = i;
if(big < j) {
big = j;
}
printf("bigger one is %d \n",big);
if(i < j) {
big = j;
} else {
big = i;
}
printf("bigger one (using else) is %d \n",big);
}
Related examples in the same category