Tanmoy
Tanmoy

Reputation: 45692

A range of objects from a list

I am having a List of say 100 objects. Now I want to get object from 50th to 60th. How can I do it. I except there will be a simple linq query or lambda expression that I can use. But I am very new to LINQ and could not find a way searching.

Upvotes: 0

Views: 181

Answers (1)

Christian C. Salvadó
Christian C. Salvadó

Reputation: 828090

You can use Skip and Take:

var range = objectList.Skip(50).Take(10);

Upvotes: 3

Related Questions