Question PSC-COND-0055
MediumWhat will be the output of the following pseudocode?
Integer a = 4, b = 7
if (a mod 2 == 0)
if (b mod 2 == 0)
Print "both even"
else
Print "only a even"
end if
else if (b mod 2 == 0)
Print "only b even"
else
Print "both odd"
end if
- A.
only a even
- B.
only b even
- C.
Sign up free to see the answer and a step-by-step explanation.