示例#1
0
        protected override long ComputeResultLogic(Day9InputModel input)
        {
            var result     = Day9Helper.GetFirstNonValidNumber(input, 25);
            var allNumbers = new List <long>();

            allNumbers.AddRange(input.Preamble);
            allNumbers.AddRange(input.RestOfInput);

            var sum = Day9Helper.GetSumOfMinAndMaxOfContigousSum(result, allNumbers.ToArray());

            return(sum);
        }
示例#2
0
        protected override long ComputeResultLogic(Day9InputModel input)
        {
            var result = Day9Helper.GetFirstNonValidNumber(input, 25);

            return(result);
        }