Example #1
0
        public int ProcessPuzzleOutputs(string input)
        {
            BotNet workspace = PrepareWorkspace(input);

            workspace.RunProcessing();

            return(workspace.GetOutput(0).Values[0] *
                   workspace.GetOutput(1).Values[0] *
                   workspace.GetOutput(2).Values[0]);
        }
Example #2
0
        public int ProcessPuzzle(string input)
        {
            BotNet workspace = PrepareWorkspace(input); int comparedBotId = 0;

            workspace.OnValueCompared += delegate(int low, int high, int id)
            {
                Console.WriteLine("Bot {0} compared low {1} and high {2}", id, low, high);
                if (low == 17 && high == 61)
                {
                    comparedBotId = id;
                }
            };

            workspace.RunProcessing();

            return(comparedBotId);
        }