This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python3 | |
| from numba import jit | |
| from numpy import bitwise_and as np_and | |
| @jit(nopython=True) | |
| def generator_part1(previous:int, mult:int) -> int: | |
| while True: | |
| previous = (previous * mult) % 2147483647 | |
| yield previous |