# data[].attributes.body
Answer the following questions:

1) What condition must be true for the if block to execute?

2)What happens if the condition in an if statement is false?

3)When should you use an if-else-if ladder instead of multiple if statements?”

# data[].attributes.body
1. To execute an if statement, the test condition of if statement must be true.

2. If the test condition of if statement is false then the body of if statement is skipped which means that it will not be executed.

3. We use if else if ladder when we have many choices but only one should be executed according to the given condition. Basically it is more faster because if the condition is true then the relevent statement is printed and all other blocks of if statement are skipped. So it is easy and faster as compared to multiple if statements.

# data[].attributes.body
1. In order to execute a block of statement, the condition in the if statement must be true

2. If the test condition is false it is ignored ( does not get executed) and the compiler moves to the next block of statement

3. We use if else if ladder when there are multiple options but only one block of statement must be executed. It saves the time for compiling as it only enters the block of statement if the related condition is true so programmers prefer if else if ladder over multiple if statement

:)

# data[].attributes.body
1. For the if block to run, its condition must return a true value upon evaluation. Only then will the enclosed statements be executed.

2. If the condition inside an if statement evaluates to false, the program bypasses that block entirely, and no action within it is performed.

3. An if-else-if ladder is ideal when dealing with multiple conditional branches where only one outcome should occur. It ensures that once a matching condition is found, the rest are ignored — leading to cleaner and more optimized co

de.

# data[].attributes.body
1. The if block executes only when its condition evaluates to true.

2. If the condition is false, the program skips the if block and moves on.

3. Use an if-else-if ladder when multiple conditions exist but only one should be executed, ensuring better readability and performance.

# data[].attributes.body
>the if block will execute if the condition we are testing is true, otherwise the else block will execute

> if the condition in the if statement is false then the compiler will not enter the if block and else block will be executed

>we should use if else if ladder instead of if statements when we want to choose among multiple options/conditions, also when we want to execute else block if all the conditions are false

# data[].attributes.body
To execute if block the the test condition should be true

If the condition in an if statement is false then the else block is executed

We should use if-else-if ladder when we have multiple conditions and we have to execute one of them

# data[].attributes.body
1)To execute if block the the test condition should be true that age should be less than or equal to 18.

2)If the condition in an if statement is false then the else block will be executed.

3)We should use if-else-if ladder when we have multiple conditions and we have to choose one of them

# data[].attributes.body
1. The if condition will only execute if the given condition is true.

2. If the condition of if statement is false then the compiler will skip them and program will end.

3. If else if ladder is more useful than multiple if statements because it saves the time and choose one true condition from many choices.

# data[].attributes.body
1. The compiler will only exercute if statement if the given condition evaluates to true.

2. The compiler will ignore the set of if statements if the given condition evaluates to false.

3. If else if statement is used when there are many choices and only one should be executed. It is fast and more useful than multiple if statements.

# data[].attributes.body
1. To execute if statement condition given in the code must be true

2. If the condition give to if statement is false then it skips the block of statement and end the code which means it will not execute the code

3. we use if else if leader when we have many choices but we have to exceute only one statment according to condition