After completing this chapter, you will be able to
Use the if else conditional statement to control code execution.
Use the switch statement.
Use a while loop and a do...while loop to execute code repeatedly.
Use different types of for loops to iterate through ranges of values.
The if statement evaluates an expression and, based on the results, determines which code, if any, executes within a program. More complex if statements can control which code executes based on multiple conditions. If you’ve booked a flight on the Internet, you know about ...