You are here

Two Way Selection within C++

6 February, 2015 - 14:39

The syntax for the if then else control structure within the C++ programming language is:

if (expression)   statement; else   statement; 


Note: The test expression is within the parentheses, but this is not a function call. The parentheses are part of the control structure. Additionally, there is no semicolon after the parenthesis following the expression.