Parallel for loops in .NET C# z

  • The start index: this is inclusive, i.e. this will be the first index value in the loop
  • The end index: this is exclusive, so it won’t be processed in the loop
  • An Action of int which represents the method that should be executed in each loop, where int is the actual index value
Parallel for loops in .NET C# z
Parallel.For(0, 10, index =>
{
    Console.WriteLine("Task Id {0} processing index: {1}",
        Task.CurrentId, index);
});
Parallel for loops in .NET C# z

 

Parallel for loops in .NET C# z,布布扣,bubuko.com

Parallel for loops in .NET C# z

上一篇:PHP中设置、使用、删除Cookie方法


下一篇:前台JSP页面独立化