diff options
| author | 2022-12-28 11:58:20 +0100 | |
|---|---|---|
| committer | 2022-12-28 11:58:20 +0100 | |
| commit | c22544594e251613a5dbf6c4ee505716867e55e6 (patch) | |
| tree | 16abda419325121eb6a36acc306697f7acba6497 /day20/test_init.py | |
| parent | 1cf8cf3f2182bb010b60f7c916fe2cd030df1658 (diff) | |
| download | 2022-c22544594e251613a5dbf6c4ee505716867e55e6.tar.gz 2022-c22544594e251613a5dbf6c4ee505716867e55e6.tar.bz2 2022-c22544594e251613a5dbf6c4ee505716867e55e6.zip | |
Day 20 [WIP]
Diffstat (limited to 'day20/test_init.py')
| -rw-r--r-- | day20/test_init.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/day20/test_init.py b/day20/test_init.py index b3ccc44..24b94cb 100644 --- a/day20/test_init.py +++ b/day20/test_init.py | |||
| @@ -25,3 +25,11 @@ def test_rotation(): | |||
| 25 | 25 | ||
| 26 | items = AssignmentOne.move(items, 4) | 26 | items = AssignmentOne.move(items, 4) |
| 27 | assert items == [1, 2, -3, 4, 0, 3, -2] | 27 | assert items == [1, 2, -3, 4, 0, 3, -2] |
| 28 | |||
| 29 | |||
| 30 | def test_get_nth_number_after_0(): | ||
| 31 | items = [1, 2, -3, 4, 0, 3, -2] | ||
| 32 | |||
| 33 | assert AssignmentOne.get_nth_number_after_0(items, 1000) == 4 | ||
| 34 | assert AssignmentOne.get_nth_number_after_0(items, 2000) == -3 | ||
| 35 | assert AssignmentOne.get_nth_number_after_0(items, 3000) == 2 | ||
