scrapbook.qujck.com
How to cancel Parallel.ForEach
static void Main(string[] args) { List waiters = new List(); for (int i = 0; i < 1000; i++) { waiters.Add(new RandomWait()); } int counter = 0; ParallelOption…