Friday

if & else statements

if statement :-
                           As everyone knows even in english when we write if then in fact a condition is being gone to be implemented by us. Similarly here in C++ we use ' if ' when we want to implement any condition on any statement. When the condition is fulfilled only then the statement is executed.

         


if and else statements  :-
                            If by chance ' if ' statement does not fulfill then else statement is printed. In other words we can say it's the second option for compiler.

 





No comments:

Post a Comment