Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Parallel Class
using System.Collections.Generic;
using System.Threading.Tasks;
namespace ParallelLibrary
public class FoolCollector
public List<Fool> ChainOfFools { get; set; }
public void Collect()
var fools = new List<Fool>()
new Fool("Jim"),
new Fool("Bexley"),
new Fool("Lister")
ChainOfFools = new List<Fool>();
Parallel.ForEach(fools, ChainOfFools.Add);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.