Heterogenous containers, as opposed to regular homogenous containers, are containers containing different types; that is, in homogenous containers, such as std::vector, std::list, std::set, and so on, every element is of the same type. A heterogeneous container is a container where elements may have different types.
Heterogeneous containers
Static-sized heterogenous containers
C++ comes with two heterogeneous containers, std::pair and std::tuple. As std::pair is a subset of std::tuple with only two elements, we will only focus on std::tuple.
The std::tuple container
The...