A nested if statement is an if statement that is placed within another if statement. It allows for more complex conditional logic by evaluating multiple conditions.
Related terms
If statement: An if statement is used to perform actions based on specified conditions. It evaluates whether a certain condition is true or false.
Boolean expression: A boolean expression is an expression that evaluates to either true or false. It is often used as the condition in an if statement.
Control flow: Control flow refers to the order in which statements are executed in a program. If statements, including nested ones, control the flow of execution based on specified conditions.