No. of functions from an $m$ element set to an $n$ element set is $n^m$ as for each of the $m$ element, we have $n$ choices to map to, giving $\underbrace{n \times n \times \dots n}_{m \text{ times}} = n^m$.
PS: Each element of the domain set in a function must be mapped to some element of the co-domain set.