Sets and functions do form a category .
The objects of are sets and its arrows are functions.
For any set we identify with the identity function on , .
is indeed associative.
Each poset is a category.
The objects of each poset are its elements and we construct an arrow for every pair of objects iff .
Reflexivity () and transitivity () provide a construction for and , respectively.
Each monoid is a category.
The objects of each monoid are its elements and we construct for every pair of elements an arrow .
The existence of an identity element and associativity, as required by the monoid structure, immediately provide us with a construction for and associativity of .