# Why is iterating over an Iterators.drop slower than iterating over the parent?

**URL:** https://discourse.julialang.org/t/why-is-iterating-over-an-iterators-drop-slower-than-iterating-over-the-parent/54315
**Category:** General Usage
**Tags:** question, iterators
**Created:** [January 31, 2021, 7:53am UTC](https://discourse.julialang.org/t/why-is-iterating-over-an-iterators-drop-slower-than-iterating-over-the-parent/54315 "2021-01-31T07:53:29Z")
**Posts on this page:** 1
**Showing post:** 3

<div class="post-metadata">

### Author: ![rafael.guerra](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/rafael.guerra/32/216610_2.png) [@rafael.guerra](https://discourse.julialang.org/u/rafael.guerra)
#### Post date: [January 31, 2021, 3:54pm UTC](https://discourse.julialang.org/t/why-is-iterating-over-an-iterators-drop-slower-than-iterating-over-the-parent/54315/3 "2021-01-31T15:54:18Z")

</div>

Just in case, @stevengj’ s solution posted [here](https://discourse.julialang.org/t/getting-the-last-element-of-an-iterator/49696/15) for computing the last element of an iterator is lightning-fast:

```julia
julia> @btime first(Iterators.reverse($itr))
  6.600 ns (0 allocations: 0 bytes)
(3000, 3000)

```

---

_[View the full topic](https://discourse.julialang.org/t/why-is-iterating-over-an-iterators-drop-slower-than-iterating-over-the-parent/54315)._
