Program to show different Relational Operators In C Programming Language

Relational Operators


/* program to show
       conditional operators
*/

  #include<stdio.h>
  #include<conio.h>
 
  void main ()
  {  //clrscr ();
       int a, b;
      clrscr();
     printf(" Enter two Numbers \n");
     scanf("%d%d",&a,&b);

     // ternary or conditional operator

     (a>=b)?printf("%d is >= %d\n",a,b):printf("%d is < %d \n",a,b);
     getch();

     }

conditional-operator 

     

Output


conditional-operator-output 



Facebook Likes

Youtube