(lhs: int, rhs: int)
| 60 | |
| 61 | |
| 62 | def _extended_gcd(lhs: int, rhs: int) -> tuple[int, int, int]: |
| 63 | if rhs == 0: |
| 64 | return lhs, 1, 0 |
| 65 | gcd, x1, y1 = _extended_gcd(rhs, lhs % rhs) |
| 66 | return gcd, y1, x1 - (lhs // rhs) * y1 |
| 67 | |
| 68 | |
| 69 | def _mod_inverse(value: int, modulus: int) -> int: |
no outgoing calls
no test coverage detected
searching dependent graphs…