Covariant Hom Functor is Functor

Theorem
Let $\mathbf{Set}$ be the category of sets.

Let $\mathbf C$ be a locally small category.

Let $C \in \mathbf C_0$ be an object of $\mathbf C$.

Let $\operatorname{Hom}_{\mathbf C} \left({C, \cdot}\right): \mathbf C \to \mathbf{Set}$ be the covariant representable functor based at $C$.

Then $\operatorname{Hom}_{\mathbf C} \left({C, \cdot}\right)$ is a functor.

Proof
For brevity and readability, let us write $\operatorname{Hom}$ for $\operatorname{Hom}_{\mathbf C}$.

For any object $D$ of $\mathbf C$ and morphism $f: C \to D \in \operatorname{Hom} \left({C, D}\right)$ we have:


 * $\operatorname{Hom} \left({C, \operatorname{id}_D}\right) \left({f}\right) = \operatorname{id}_D \circ f = f$

and so $\operatorname{Hom} \left({C, \operatorname{id}_D}\right) = \operatorname{id}_{\operatorname{Hom} \left({C, D}\right)}$.

Thus $\operatorname{Hom} \left({C, \cdot}\right)$ preserves identity morphisms.

For composable morphisms $g$ and $f$ of $\mathbf C$ we furthermore have:

for any $x \in \operatorname{Hom} \left({C, \operatorname{dom} f}\right)$ composable with $f$.

Hence the result, by Equality of Mappings.