A single-valued function is an emphatic term for a mathematical function in the usual sense. That is, each element of the function's domain maps to a single, well-defined element of its range. By default, we always consider function as a single-valued function except when clearly mentioned that function is a multi-valued function.
So, the number of single valued functions from $A$ to $B =$ number of functions from $A$ to $B$.
Lets take an example:
$A =\{1,2\} ,B=\{a,b \}$
- $f(1)=f(2)=a$
- $f(1)=f(2)=b$
- $f(1)=a$ and $f(2) =b$
- $f(1)=b$ and $f(2) =a$
The total number of single-valued functions from set $A$ to another set $B =∣ B∣^{∣A ∣}=n^m$. This is because for every element in $A$ we have $\mid B\mid$ possibilities in the function.
The correct answer is $n^m .$