public void testWithActualPartB() { var sot = new DaySix(); var result = sot.GetErrorCorrectedMessage(DaySix.PUZZLE_INPUT, true); Assert.Equal("odqnikqv", result); }
public void PartA_Actual() { var sut = new DaySix(); var result = sut.PartA(); Assert.Equal("3969", result); }
public void Test_Input_Repeats_After_5_Iterations() { int [] banks = new int [] { 0, 2, 7, 0 }; int iterations = DaySix.IterateUntilRepeatedState(banks); Assert.AreEqual(5, iterations); }
public void PartB_Actual() { var sut = new DaySix(); var result = sut.PartB(); Assert.Equal("42123", result); }
public void testWithActualPartA() { var sot = new DaySix(); var result = sot.GetErrorCorrectedMessage(DaySix.PUZZLE_INPUT, false); Assert.Equal("asvcbhvg", result); }
public void testGetErrorCorrectedMessageA() { var input = @"eedadn drvtee eandsr raavrd atevrs tsrnev sdttsa rasrtv nssdts ntnada svetve tesnvt vntsnd vrdear dvrsen enarar"; var sot = new DaySix(); var resultDesc = sot.GetErrorCorrectedMessage(input, false); Assert.Equal("easter", resultDesc); var resultAsc = sot.GetErrorCorrectedMessage(input, true); Assert.Equal("advent", resultAsc); }
public void SumCustomFormQuestionAnswers() { string filePath = @"Six\DaySixTestInputA.txt"; var sut = new DaySix(); var result = sut.SumCustomFormUniqueQuestionAnswers(filePath); Assert.Equal(11, result); }
public void SumCustomFormAllYesAnswers() { string filePath = @"Six\DaySixTestInputA.txt"; var sut = new DaySix(); var result = sut.SumCustomFormAllYesAnswers(filePath); Assert.Equal(6, result); }
public void SquareInchesOfFabricWithTwoOrMoreClaims() { var filePath = @"Six\DaySixTestInput.txt"; var sut = new DaySix(); var result = sut.FindLargestArea(filePath); Assert.Equal(17, result); }
public void GetIdOfUnoverlappingClaim() { var filePath = @"Six\DaySixTestInput.txt"; var sut = new DaySix(); var result = sut.FindSizeOfTargetArea(filePath, 32); Assert.Equal(16, result); }
public void TestNumberOfStepsUntilDuplicateState() { int[] initialBlocks = new[] { 0, 2, 7, 0 }; var sut = new DaySix(); var result = sut.NumberOfStepsUntilDuplicateState(initialBlocks); Assert.Equal(5, result); }
public void TestNumberOfStepsBetweenFirstDuplicate() { int[] initialBlocks = new[] { 0, 2, 7, 0 }; var sut = new DaySix(); var result = sut.NumberOfStepsBetweenFirstDuplicate(initialBlocks); Assert.Equal(4, result); }
static void Main() { DayOne.TaskOne(); DayOne.TaskTwo(); DayTwo.TaskOne(); DayTwo.TaskTwo(); DayThree.TaskOne(); DayThree.TaskTwo(); DayFour.TaskOne(); DayFour.TaskTwo(); DaySix.TaskOne(); DaySix.TaskTwo(); Console.Read(); }
public void Part2_CalculateResultForSimpleExample() { var input = new[] { "abc", "", "a", "b", "c", "", "ab", "ac", "", "a", "a", "a", "a", "", "b" }; DaySix.CalculateResultForPartTwo(input).Should().Be(6); }
public void Part2_CalculateResult() { var input = File.ReadAllLines(@"Input/input6.txt"); System.Console.WriteLine(DaySix.CalculateResultForPartTwo(input)); }
public void Day6Part1Example() => Assert.AreEqual(5, DaySix.ComputePartOne(NewExampleListInstance));
public void Redistribute_3_1_2_3_Produces_0_2_3_4() { int [] banks = new int [] { 3, 1, 2, 3 }; banks = DaySix.Iterate(banks); CollectionAssert.AreEqual(new int [] { 0, 2, 3, 4 }, banks); }
public void Redistribute_2_4_1_2_Produces_3_1_2_3() { int [] banks = new int [] { 2, 4, 1, 2 }; banks = DaySix.Iterate(banks); CollectionAssert.AreEqual(new int [] { 3, 1, 2, 3 }, banks); }
public void Redistribute_0_2_7_0_Produces_2_4_1_2() { int [] banks = new int [] { 0, 2, 7, 0 }; banks = DaySix.Iterate(banks); CollectionAssert.AreEqual(new int [] { 2, 4, 1, 2 }, banks); }
public void Day6_P2Test() { var input = File.ReadAllText("./Files/Day_6/Day6_Test.input").Split("\r\n\r\n"); Assert.AreEqual(6, DaySix.Day6_P2(input)); }
public void DaySixPartTwoReturnsCorrectly(string input, int expected) { var result = DaySix.PartTwo(input); Assert.AreEqual(expected, result); }
public void Day6Part1() => Assert.AreEqual(14029, DaySix.ComputePartOne(NewInputListInstance));
public void Day6Part2Example() => Assert.AreEqual(4, DaySix.ComputePartTwo(NewExampleListInstance));
public void Day6Part2() => Assert.AreEqual(2765, DaySix.ComputePartTwo(NewInputListInstance));