core: Refactor iterators

Simplifying the code of methods: nth, fold, rposition
and iterators: Filter, FilterMap, SkipWhile
Adding basic benchmarks