public string part_one(string input) { var cups = Cups.Create(input.ToCharArray().Select(ch => ch - '0')); while (cups.Turn < 100) { cups.Next(); } return(cups.Answer()); }
public long part_two(string input) { var cups = Cups.Create(input.ToCharArray().Select(ch => ch - '0'), 1_000_000); while (cups.Turn < 10_000_000) { cups.Next(); } return((long)cups.Search(1).Next.Value *cups.Search(1).Next.Next.Value); }