Answer:

The ENTIRE false branch of the first IF was skipped. This is the way two-way choices always work. It doesn't matter that the false branch has lots of complicated stuff in it. If it is skipped, it is skipped completely.

(1) PRINT "Do you want coffee? (Answer YES or NO)"
(2) INPUT ANSWER$

(3) IF ANSWER$ = "YES" THEN  <-- true
(4)   LET PRICE = 1.05  <-- true branch is executed

    ELSE
      Whatever...    <-- false branch is skipped
    END IF

(5) PRINT "Your beverage costs:", PRICE
(6) END

Complete Control Structure Skipped

Another way to describe the statements that were skipped is to say that: the entire nested IF was skipped. This is one reason why keeping track of matching brackets is important:

Complete control structures are treated as a unit. They (and the statements they control) are completely included or completely excluded from execution.

When things get complicated, this rule is how you figure out what is going on.

Let us practice this. Say that the user wants tea for breakfast. The monitor screen looks like this:

Do you want coffee? (Answer YES or NO)
? NO
Do you want tea? (Answer YES or NO)
? YES
Your beverage costs:   1.50

Here is how the program did this. The statements are numbered in the order that they executed:

(1) PRINT "Do you want coffee? (Answer YES or NO)"
(2) INPUT ANSWER$

(3) IF ANSWER$ = "YES" THEN  <-- false
      LET PRICE = 1.05       <-- true branch is skipped

    ELSE
      ' decide between tea and milk                |
(4)   PRINT "Do you want tea? (Answer YES or NO)"  |
(5)   INPUT ANSWER$                                |
                                                   |
(6)   IF ANSWER$ = "YES" THEN                      | <-- false branch is executed
(7)     LET PRICE = 1.50                           |
      ELSE                                         |
        LET PRICE = .89                            |
      END IF                                       |

    END IF

(8) PRINT "Your beverage costs:", PRICE
(9) END

QUESTION 11:

Although the figure says that "the false branch is executed," not all of the statements in the false branch were executed. Why is this?