Skip to content

Commit 21103b5

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent d1ed34b commit 21103b5

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

bit_manipulation/sliding_window_xor.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,9 @@ class SlidingWindowXOR:
2020
result = solver.compute(n, k, x, multiplier, increment, modulo)
2121
"""
2222

23-
def compute(self, n: int, k: int, x: int, multiplier: int,
24-
increment: int, modulo: int) -> int:
23+
def compute(
24+
self, n: int, k: int, x: int, multiplier: int, increment: int, modulo: int
25+
) -> int:
2526
"""
2627
Compute cumulative XOR of all sliding windows of size k.
2728
@@ -62,7 +63,7 @@ def compute(self, n: int, k: int, x: int, multiplier: int,
6263
(2, 1, 2, 3, 4, 5, 2),
6364
(5, 2, 1, 1, 1, 100, 4),
6465
(3, 5, 5, 2, 1, 100, 0),
65-
(4, 4, 3, 1, 0, 10, 0)
66+
(4, 4, 3, 1, 0, 10, 0),
6667
]
6768

6869
for idx, (n, k, x, m, inc, mod, expected) in enumerate(test_cases, 1):

0 commit comments

Comments
 (0)