def test_tas2(self): self.assertEqual(task2(""), "a2582a3a0e66e6e86e3812dcb672a272") self.assertEqual(task2("AoC 2017"), "33efeb34ea91902bb2f59c9920caa6cd") self.assertEqual(task2("1,2,3"), "3efbe78a8d82f29979031a4aa0b16a9d") self.assertEqual(task2("1,2,4"), "63960835bcdc130f0b66d7ff4f6a5a8e") self.assertEqual(task2(read_str("input.txt")), "2f8c3d2100fdd57cec130d928b0fd2dd")
def test_task2(self): self.assertEquals(task2("ne,ne,ne".split(",")), 3) self.assertEquals(task2("ne,ne,sw,sw".split(",")), 2) self.assertEquals(task2("ne,ne,s,s".split(",")), 2) self.assertEquals(task2("se,sw,se,sw,sw".split(",")), 3) self.assertEquals(task2("n,n,s,s".split(",")), 2) self.assertEquals(task2(read("input.txt")), 1560)
def test_task2(self): self.assertEquals(task2(get_map("test.txt")), 2) self.assertEquals(task2(get_map("input.txt")), 189)
def test_task2(self): self.assertEqual(task2([0, 3, 0, 1, -3]), 10) self.assertEqual(task2(read_input()), 24774780)
def test_task2(self): self.assertEqual(task2("flqrgnkx"), 1242) self.assertEqual(task2("ljoxqyyw"), 1074)
def test_task2(self): self.assertEqual(task2("example.txt"), 60) self.assertEqual(task2("input.txt"), 333)
def test_task2(self): self.assertEqual(task2(328, 50000000), 2316253)
def test_task2(self): self.assertEqual(task2("test.txt"), 10) self.assertEqual(task2("input.txt"), 6619)
def test_task2(self): self.assertEquals(task2(), 208)
def test_task2(self): self.assertEqual(task2([0, 2, 7, 0]), 4) self.assertEqual(task2(read_input()), 2793)
def test_task2(self): self.assertEqual(task2(65, 8921, 5), 0) self.assertEqual(task2(65, 8921, 5 * 1000 * 1000), 309) self.assertEqual(task2(722, 354, 5 * 1000 * 1000), 285)
def test_do_permutation(self): self.assertEqual( task2(read_moves("input.txt"), list("abcdefghijklmnop"), 1000000000), "bpjahknliomefdgc")