# std::tuple_element<std::span>

From cppreference.com
< cpp‎ | container‎ | span

Defined in header `<span>` |  |
template< std::size_t I, class T, std::size_t N > struct tuple_element<I, std::span<T, N> >; |  | (since C++20)

Provides compile-time indexed access to the type of the elements of the span using tuple-like interface. The program is ill-formed if I >= N or if N == std::dynamic_extent.

### Member types

Member type | Definition
type | the type of elements of the span, i.e., `T`

### Example

| This section is incomplete Reason: no example

### See also

tuple_element | obtains the type of the specified element (class template specialization)
std::tuple_element<std::pair> (C++11) | obtains the type of the elements of `pair` (class template specialization)
std::tuple_element<std::array> | obtains the type of the elements of `array` (class template specialization)

Retrieved from "https://en.cppreference.com/mwiki/index.php?title=cpp/container/span/tuple_element&oldid=110689"