0
Why doesn't the if statement have ;
2 Answers
+ 4
(as no language is mentioned so I am assuming it to be C/C++ )
Ans :-
This is because semicolon is used to show the termination of one statement and while using *if-else* statment we generally execute a group of statements which are enclosed in braces"{ }" where "{" marks the beginning of the group and "}" marks the end.
Same is in the case of loops also
+ 1
Thanks for your response. First time poster hence didn look to see if it would get posted in the same chapter. Your response makes sense.