Kotlin sequence "skip" first N entries

KotlinSequences

Kotlin Problem Overview


How can I "skip" the first N entries of a kotlin sequence/list?

I am looking for the kotlin equivalent of C# LINQ "skip".

Kotlin Solutions


Solution 1 - Kotlin

You are probably looking for the "drop" function known for example from from lodash:

val seq = 1..10

seq.drop(5)
> [6, 7, 8, 9, 10]

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestionGameScriptingView Question on Stackoverflow
Solution 1 - KotlinGameScriptingView Answer on Stackoverflow