Skip to content

Commit 66919bd

Browse files
author
Akibuzzaman Akib
committed
style: fix ruff linting — replace ambiguous multiplication sign, apply formatting
1 parent 53a30c4 commit 66919bd

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

maths/fibonacci_fast.py

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,8 @@
1515
"""
1616

1717

18-
def _mat_mul(
19-
a: list[list[int]], b: list[list[int]]
20-
) -> list[list[int]]:
21-
"""Multiply two 2×2 integer matrices.
18+
def _mat_mul(a: list[list[int]], b: list[list[int]]) -> list[list[int]]:
19+
"""Multiply two 2x2 integer matrices.
2220
2321
>>> _mat_mul([[1, 1], [1, 0]], [[1, 0], [0, 1]])
2422
[[1, 1], [1, 0]]
@@ -36,10 +34,10 @@ def _mat_mul(
3634

3735

3836
def _mat_pow(matrix: list[list[int]], power: int) -> list[list[int]]:
39-
"""Raise a 2×2 integer matrix to a non-negative integer power using
37+
"""Raise a 2x2 integer matrix to a non-negative integer power using
4038
fast exponentiation (repeated squaring).
4139
42-
:param matrix: A 2×2 matrix represented as a list of lists.
40+
:param matrix: A 2x2 matrix represented as a list of lists.
4341
:param power: Non-negative integer exponent.
4442
:return: matrix ** power
4543

0 commit comments

Comments
 (0)