27 Iterators library [iterators]

27.8 Container access [iterator.container]

In addition to being available via inclusion of the <iterator> header, the function templates in [iterator.container] are available when any of the following headers are included: <array>, <deque>, <forward_­list>, <list>, <map>, <regex>, <set>, <string>, <unordered_­map>, <unordered_­set>, and <vector>.
template <class C> constexpr auto size(const C& c) -> decltype(c.size());
Returns: c.size().
template <class T, size_t N> constexpr size_t size(const T (&array)[N]) noexcept;
Returns: N.
template <class C> constexpr auto empty(const C& c) -> decltype(c.empty());
Returns: c.empty().
template <class T, size_t N> constexpr bool empty(const T (&array)[N]) noexcept;
Returns: false.
template <class E> constexpr bool empty(initializer_list<E> il) noexcept;
Returns: il.size() == 0.
template <class C> constexpr auto data(C& c) -> decltype(c.data()); template <class C> constexpr auto data(const C& c) -> decltype(c.data());
Returns: c.data().
template <class T, size_t N> constexpr T* data(T (&array)[N]) noexcept;
Returns: array.
template <class E> constexpr const E* data(initializer_list<E> il) noexcept;
Returns: il.begin().