For a function from set $A$ to set $B$, we need to have a mapping for all elements of $A$ and mapping must be unique.
Let number of elements in $A$ be $m$ and that in $B$ be $n$
So, if we consider an element from $A,$ it can be mapped to any of the element from $B.$ i.e., it has $n$ possibilities when a function is formed. Similarly, for all other members also there are $n$ possibilities as one element from $A$ can be mapped to only a single element in $B$ (though reverse need not true). So, for $m$ elements in $A,$ we totally have $\underbrace{n \times \dots \times n}_{m \text{ times}} = n^m$ possible functions.
In the question Number of elements (functions) in $f$ is $2^{2^4}$ as $\{0,1\}^4$ contains $2^4$ elements. So, number of functions from $S$ to $\{0,1\}$ will be $2^{2^{2^4}}$. So, $\log_2 \log_2 N = 2^4 = 16.$