예제 #1
0
 def test_3(self):
     r, s = solve_15(path(__file__, 'tests/sample-3.txt'))
     self.assertEqual(39514, r)
     r, s = solve_15(path(__file__, 'tests/sample-3.txt'), 4, False)
     self.assertEqual(31284, r)
예제 #2
0
 def test_blah6(self):
     r = solve_15(path(__file__, 'tests/movement-5.txt'))
     self.assertEqual(27730, r)
예제 #3
0
 def test_2(self):
     r, s = solve_15(path(__file__, 'tests/sample-2.txt'))
     self.assertEqual(36334, r)
예제 #4
0
 def test_1(self):
     r, s = solve_15(path(__file__, 'tests/sample-1.txt'))
     self.assertEqual(27730, r)
     r, s = solve_15(path(__file__, 'tests/sample-1.txt'), 15, False)
     self.assertEqual(4988, r)
예제 #5
0
 def test_blah2(self):
     r = solve_15(path(__file__, 'tests/enemy-selection-2.txt'))
     self.assertEqual(27730, r)
예제 #6
0
 def test_real_part_2(self):
     r, s = solve_15(path(__file__, 'input.txt'),
                     elf_strength=25,
                     allow_elves_to_die=False)
     self.assertEqual(53725, r)
예제 #7
0
 def test_real_part_1(self):
     r, s = solve_15(path(__file__, 'input.txt'))
     self.assertEqual(227290, r)
예제 #8
0
 def test_6(self):
     r, s = solve_15(path(__file__, 'tests/sample-6.txt'))
     self.assertEqual(18740, r)
     r, s = solve_15(path(__file__, 'tests/sample-6.txt'), 34, False)
     self.assertEqual(1140, r)
예제 #9
0
    def test_5(self):
        r, s = solve_15(path(__file__, 'tests/sample-5.txt'))
        self.assertEqual(28944, r)

        r, s = solve_15(path(__file__, 'tests/sample-5.txt'), 12, False)
        self.assertEqual(6474, r)
예제 #10
0
 def test_4(self):
     r, s = solve_15(path(__file__, 'tests/sample-4.txt'))
     self.assertEqual(27755, r)
     r, s = solve_15(path(__file__, 'tests/sample-4.txt'), 15, False)
     self.assertEqual(3478, r)