One interpretation for a power of natural numbers, such as , is that it is counting a certain collection of functions: in this case, the number of functions from a sixelement set to a tenelement set. (One way to think about it is that is the number of sixdigit combinations from 000000 to 999999, and each combination corresponds to a function from to : the first digit is the image of , the second digit is the image of , etc.)
In general, the number is the number of functions from an element set to a element set. This is somewhat analogous to standard interpretations of other arithmetical operations:
 is the number of elements in the Cartesian product of an element set and an element set.
 is the number of elements in the disjoint union of an element set and an element set.
So and are arithmetical shadows of the categorical operations “Cartesian product” and “disjoint union” on sets. Is exponentiation the shadow of a categorical operation sending a pair of sets and to the set of functions from to ? The answer is yes: this set of functions is an example of an exponential object in the category of sets, and is written . This is one way of interpreting similarly notated sets like : as the set of functions from a 3element set (such as ) to . We could instead let be any set, and consider as the set of functions , i.e. the set of indexed families of elements of .
So what are the categorical properties of this exponential object? Well, comes with three maps : projection onto each coordinate. In other words, there’s a map
that takes a number and a point and sends it to the th coordinate of . More generally, there’s a canonical evaluation map
that sends an element and a function to the element . In fact, is universal among sets equipped with a function : given such a function, each element gives us a function obtained from by holding the second input constant at , so we get a function .
This universal property is the categorical definition of an exponential object: if is any category with finite products (““), then for any two objects in , their exponential object is an object with the property that morphisms are in natural onetoone correspondence with morphisms .
Here are some examples of exponential objects:

The ordered set , regarded as a category with the relation as its morphisms, is a very simple category with nonetheless interesting exponential objects.
The product operation in this category, as in any total order, is the “min” operation denoted , so that , , and . (If we interpret and as the truth values False and True, then this categorical product is the “and” operation. “Max” is the categorical coproduct, denoted by .)
Then given two truth values and , the exponential is the largest element such that . You can check that this works out to: if and , and otherwise. In other words, the exponential object is the implication !
 More generally, if is any Boolean algebra, regarded as a category via its poset structure, the exponential object for two elements is the implication .
 If is a group, the category of sets has exponential objects: if and are two sets, then the exponential object is the set of all functions (whether or not they respect the action!) and the action on is given by conjugation: the action of on is the function .
 If and are categories, i.e. objects in the category of categories, then the exponential object is the category whose objects are functors and whose morphisms are natural transformations between them.
Do exponential objects always exist?
No: in fact, it’s rather common for exponential objects not to exist. If a category has an exponential object for every pair of objects and , then one way of interpreting the correspondence
“morphisms correspond to morphisms “
is as an adjunction between the functors and ; as such, the functor automatically must preserve all colimits. In the category of sets, this is just a soupedup version of the statement that cartesian products distribute over disjoint unions:
,
In other categories, however, this can fail. For example, in the category of abelian groups, the categorical product and coproduct are both direct sums, and we definitely don’t have a general isomorphism
.
But in some ways this is the only problem: often if a category has enough colimits and a functor (such as ) preserves them, that functor automatically has a right adjoint (which we could call ). Such a category would not only have binary products and a terminal object , it would also have binary coproducts and an initial object , and if preserves colimits we must have
and .
In such a category, it’s possible to prove (with the Yoneda lemma, for example) that for all objects , , and :
 and .
 and .
 and .
These are exactly the laws of exponentiation for natural numbers, promoted to categorical isomorphisms, which we deduced in the first place from the interpretation of as the number of functions from an element set to an element set. But now we know they hold in a general category with finite products, finite coproducts, and exponential objects—for example, if , , and are abstract propositions in the Boolean algebra of propositional logic, where product is “and”, coproduct is “or”, and exponentiation is “implies”, they read:
 implies and implies if and only if ( or ) implies . Also, a false statement implies anything.
 implies ( implies ) if and only if ( and ) implies . Also, a proposition holds if and only if it is implied by a true statement.
 ( implies ) and ( implies ) if and only if implies ( and ). Also, everything implies a true statement.
Amazing, huh?