How to create a sequence of integers in C#?
Enumerable.Range(0, 11);
Generates a sequence of integral numbers within a specified range.
http://msdn.microsoft.com/en-us/library/system.linq.enumerable.range.aspx
You can use Enumerable.Range(0, 10);
. Example:
var seq = Enumerable.Range(0, 10);
MSDN page here.