Does the rule of product apply in this problem? Going through a course of discrete mathematics I came across this question:

A questionnaire contains six questions each having yes-no answers. For each yes response, there is a follow-up question with four possible responses.

*

*Draw a tree diagram that illustrates how many ways a single question in the questionnaire can be answered.

*How many ways can the questionnaire be answered?


The answer provided by the course is: $5^6$. Why isn't it $6 \times 5$, i.e. $30$? I would think that there are
six questions and five ways of answering each of them{no, yes-A, yes-B, yes-C, yes-D}. According to the rule of product, I multiply $5$ times $6$ which gives me $30$. Why is the answer $5^6$? I have very little background in discrete mathematics.
 A: The rule of product applies when you have two or more independent choices to be made, and the number of factors is equal to the number of independent choices. Here you have $6$ independent choices so you get $6$ factors; each of them equal $5$, so on all you get $5\times 5\times5\times 5\times5\times 5=5^6$ possibilities. The formula $6\times 5$ would apply if you had to independently (1) choose one question, and (2) answer one question.
(The latter case applies even if you need to answer the question you chose, since all questions allow for the same number of answers. This shows that independence of the choices is not an absolute necessity to have some multiplicative formula: it suffices that the number of options for a dependent choice is the same for all previous choices. For instance if you need to choose you number 1,2,3 favourite colours among a palette of 14, you have $14\times13\times12$ options, since after 1 choice there are $13$ left for the second, and then $12$ for the third place, even though the actual options that are left depend on your earlier choices.)
