if else statements are condition statements.
These are used to give conditions.
Syntax:
1.) if( any condition )
{ Statement };
2.) if( any condition )
{ Statement };
else
{ Statement };
3.)if(any condition)
{ Statement };
else if(any condition)
{ Statement };
else
{ Statement };
Eaxamples :
if
if-else
if - else if - else
These are used to give conditions.
Syntax:
1.) if( any condition )
{ Statement };
2.) if( any condition )
{ Statement };
else
{ Statement };
3.)if(any condition)
{ Statement };
else if(any condition)
{ Statement };
else
{ Statement };
Eaxamples :
if
if-else
if - else if - else
0 comments:
Post a Comment