public static void ReadFrom <TLoc, TState>(this GameOfLife <TLoc, TState> game, AlignedSpace <TLoc, TState> space) { foreach (var(pos, value) in space) { game[pos] = value; } }
public static bool ContainsValue <TPos, TVal>(this AlignedSpace <TPos, TVal> space, TVal val) { return(space.HasValue(val)); }
public static IEnumerable <(TPos, TVal)> Select <TPos, TVal>(this AlignedSpace <TPos, TVal> space, SpaceFilter <TPos, TVal> filter) { foreach (var(pos, val) in space)
public CopySpace(AlignedSpace <TPos, TVal> reference) { _source = reference; }
public RepairDroid(string program, AlignedSpace <Pos, int> map) { Map = map; _controller = Computer.From(program); _data = new DataLink(_controller); }