Dangling else (cont.)
nIt is associated with the second if (B). nTo associate it with the first, add braces around everything contained between the first if and the else.
n
nif (condition1) {
n if (condition2)
n statement1
n} else
n statement2