Let $a_1, a_2, \cdots , a_r$ be odd integers where $a_i > 1$ for $i = 1, 2, \cdots , r$. Prove that if $n = a_1a_2 \cdots a_r + 2$, then $a_i \nmid n$ for each integer $i (1 \leq i \leq r)$.
Let $a_i \mid n$, then $a_i \mid a_1a_2 \cdots a_r + 2$ also $a_i \mid a_1a_2 \cdots a_r$, thus $a_i \mid a_1a_2 \cdots a_r+2 - a_1a_2 \cdots a_r \implies a_i \mid 2$, which is not possible since $a_i > 1$ is odd integer.
Is the logic correct?
Yes, your reasoning is sound and correct.