Given two functions $f, g : X \rightarrow X$, their composition $f \circ g$ is a new function $X \rightarrow X$. When $f \circ g$ is given an argument $x \in X$, it first applies $g$ to produce an element $g(x)$, and then applies $f$ to that. The result is $f(g(x))$, and this element is defined to be the value of $f \circ g$ in $x$.
Summing up, we get what Srivatsan wrote in a comment:
$ (f \circ g)(x) = f(g(x)). $
Since we defined an operation that takes two functions $f$ and $g$ and produces a new function $f \circ g$, it makes sense to check if the operation makes the set $X^X$ of functions $X \rightarrow X$ into a monoid.
To do so, we need to prove that composition is associative, i.e.:
$ (f \circ g) \circ h = f \circ (g \circ h) $
for any choice of $f, g, h$, and also that there exists a special function $i : X \rightarrow X$, such that, for all $f$:
$ f \circ i = i \circ f = f. $
All of this is extremely easy to verify, just keep in mind that to check if two functions are equal is it sufficient to check that they have the same value on every possible argument.