It is not correct. For starters, the expression $q^\mathfrak{c}$ (where $q\in\Bbb Q$) is meaningless; I suspect that you meant $\left|\Bbb Q^\mathfrak{c}\right|$, which is indeed $\left|\Bbb N^\mathfrak{c}\right|$. But note that you do need the cardinality bars.
However, you’ve got the multiplication principle backwards: you’re making a choice amongst $\mathfrak{c}$ real numbers $|\Bbb Q|$ times, so you really want $\mathfrak{c}^{|\Bbb N|}$. Finally, $\mathfrak{c}=2^{|\Bbb N|}$, so
$$\mathfrak{c}^{|\Bbb N|}=\left(2^{|\Bbb N|}\right)^{|\Bbb N|}=2^{|\Bbb N|\cdot|\Bbb N|}=2^{|\Bbb N|}=\mathfrak{c}\;.$$
This actually shows only that there are at most $\mathfrak{c}$ continuous real-valued functions on $\Bbb R$, since it counts all functions from $\Bbb Q$ to $\Bbb R$, not just the ones that are restrictions of continuous functions from $\Bbb R$ to $\Bbb R$. To complete the argument you need to show that there are also at least that many; this is easy, since there are $\mathfrak{c}$ constant functions.
I’ve answered this in order to respond to the specific problems with your argument. The question itself has been dealt with in detail in the answers to this question.