https://youtu.be/QR6xCETmSGg

Program to show if control statement

if control statement


  /* decision Control Statements
   */

  #include<stdio.h>
  #include<conio.h>

  void main ()
  {

    int a=10;
    clrscr();
    printf("Enter the value of a which will be compared to 15\n");
    scanf("%d",&a);

    if(a>=15)
    {
    printf(" \nthe value of a is %d ",a);
    printf("\n value of a is cmpared to 15\n");
    a=a+1;
    printf("now the value of a is %d",a);

    }  // if body close

    printf(" \n Hi this is the decision control statements (if)");
    getch();

  }

if-control-statement 


  

Output

if-control-statement-output 




Facebook Likes

Youtube