Пример #1
0
        public string PartA()
        {
            CupGame game = new CupGame(Input);

            game.Play(100);
            string cupOrder = game.ListCupOrder();

            return(cupOrder);
        }
Пример #2
0
        public void CupGame_Play(int moves, string expected)
        {
            var input = "389125467";
            var sut   = new CupGame(input);

            sut.Play(moves);
            var result = sut.ListCupOrder();

            Assert.Equal(expected, result);
        }
Пример #3
0
        public string PartB()
        {
            CupGame game = new CupGame(Input, 1000000);

            game.Play(10000000);
            var  one         = game.GetCup(1);
            long right       = one.Next.Value;
            long doubleRight = one.Next.Next.Value;

            return((right * doubleRight).ToString());
        }