# Simple clarification - $\operatorname{Hom}_{\mathsf{Set}}(X,Y)$

I'm currently working through David Spivak's Category Theory for Scientists, and I'd just like to verify that I am understanding $\def\homset{\operatorname{Hom}_{\mathsf{Set}}}\homset(X,Y)$ correctly. My (informal) understanding that is that it denotes the set of all the different functions from $X \rightarrow Y$. Thus, if we let $A = \{1,2,3,4,5\}$ and $B = \{x,y\}$, we have the following answers to these questions:

a) How many elements does $\homset(A,B)$ have?

• 32 since each element in $A$ can map to one of two elements in $B$. Thus, we have $2^5 = 32$.

b) Find a set A such that for all sets $X$ there is exactly one element in $\homset(X, A)$.

• If there is exactly on element in the hom-set, this means we can only have one function from $X$ to $Y$. Thus, $A$ can be any set containing only one element.

c) Find a set $B$ such that for all sets $X$ there is exactly one element in $\homset(B, X)$.

• This is the one that I'm stuck on and made me think that perhaps I'm misunderstanding the definition given, because by what I'm given, such a set can't exist.

Could someone please confirm my thinking or clarify what I might be misunderstanding? Thanks!

-
Don't forget your friend the empty set! –  Trevor Wilson Oct 2 '13 at 4:54
I was actually thinking about that. Wasn't sure that a function could map the empty set to something, though I suppose on hind thought that the definition definitely would allow it. Thanks! –  pomegranate Oct 2 '13 at 5:08
@promegranate The function (you wasn't sure about) from $\emptyset$ to any $X$ is just the injection $\emptyset \subseteq X$. –  Pece Oct 2 '13 at 10:10

Maps from B to X can be represented in category theory as $X^{B}$.