Beispiel #1
0
        public override void PartTwo(IInput input, IOutput output)
        {
            var records        = input.AsRecords();
            var validPasswords = records.Where(r => r.IsValidBasedOnPosition()).Count();

            output.WriteProperty("Total Passwords", records.Length);
            output.WriteProperty("Number of Valid Passwords", validPasswords);
        }