[counted.iter.elem]

# 24 Iterators library [[iterators]](./#iterators)

## 24.5 Iterator adaptors [[predef.iterators]](predef.iterators#counted.iter.elem)

### 24.5.7 Counted iterators [[iterators.counted]](iterators.counted#counted.iter.elem)

#### 24.5.7.4 Element access [counted.iter.elem]

[ð](#lib:operator*,counted_iterator)

`constexpr decltype(auto) operator*();
constexpr decltype(auto) operator*() const
  requires [dereferenceable](iterator.synopsis#concept:dereferenceable "24.2 Header <iterator>&nbsp;synopsis [iterator.synopsis]")<const I>;
`

[1](#1)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/iterators.tex#L6100)

*Hardened preconditions*: length > 0 is true[.](#1.sentence-1)

[2](#2)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/iterators.tex#L6104)

*Effects*: Equivalent to: return *current;

[ð](#lib:operator-%3e,counted_iterator)

`constexpr auto operator->() const noexcept
  requires [contiguous_iterator](iterator.concept.contiguous#concept:contiguous_iterator "24.3.4.14 Concept contiguous_­iterator [iterator.concept.contiguous]")<I>;
`

[3](#3)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/iterators.tex#L6116)

*Effects*: Equivalent to: return to_address(current);

[ð](#lib:operator%5b%5d,counted_iterator)

`constexpr decltype(auto) operator[](iter_difference_t<I> n) const
  requires [random_access_iterator](iterator.concept.random.access#concept:random_access_iterator "24.3.4.13 Concept random_­access_­iterator [iterator.concept.random.access]")<I>;
`

[4](#4)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/iterators.tex#L6128)

*Hardened preconditions*: n < length is true[.](#4.sentence-1)

[5](#5)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/iterators.tex#L6132)

*Effects*: Equivalent to: return current[n];
