Search C Program

Largest value of two variables - Conditional Operator

/*    Find largest value between two variables - single line - Conditional Operator  */

int main()
 int a,b,d;

 printf("Type values of A and B : ");
 scanf("%d %d",&a,&b);
 printf("Greatest value : %d",d);
 return 0;

Related Post:
Find larger value between two variable

1 comment:

  1. please provide program to find largest of three variables using same conditional operator