According to syntax, semicolons must be required at the end of the body.
*According to syntax, if condition 1 is true then block 1 is executed, if it is false then control will pass to the else part.
* Within the else part if condition 2 is true then block 2 will execute, if it is false then control will pass to nested else.
* Within the nested else, if condition 3 is true then block 3 will execute, if it is false then block 4 will be executed.
* when we are working with nested if else at any point of time, only one block will be executed or can be executed.
*Nested concepts can be applied for if part and else part also.
*If we are applying the nested concepts to if part then it is called nested if- else, if we are applying to else part, then it is called else if ladder.
Prog: a b c d
Void main ( )
Int a, b, c, d, min;
Clrscr ( );
Print f (“Enter 4 values :”);
Scan f (“%d %d %d %d”, &a, &b, &c, &d);
If (a<b && a<c && a<d)
If (b<c && b<d)
If (c< d)
Print f (“min value is: %d”, min);
Getch ( );