Conditional Structures

In many ways, conditional logic(deciding which action to take based on user input, external conditions, or other information), is the heart programming. All conditional logic starts with a condition: a simple expression that can be evaluated to true or false. Your code can them make a decision to execute different logic depending on the outcome of the condition. To build a condition, you can use any combination of literal values or variables along with logical operators.

No comments:

Post a Comment