Liniowy generator zgodny z Python

def rng(m=2**32, a=1103515245, c=12345):
    rng.current = (a*rng.current + c) % m
    return rng.current/m

# setting the seed
rng.current = 1
for i in range(10):
  rng()
Elegant Eagle