Skip to content

Instantly share code, notes, and snippets.

@dmd
Created May 29, 2022 13:17
Show Gist options
  • Save dmd/299cf46db028fc9ce11b877fd21ccddb to your computer and use it in GitHub Desktop.
Save dmd/299cf46db028fc9ce11b877fd21ccddb to your computer and use it in GitHub Desktop.
#!/usr/bin/env python
import random
seed = 0
i = 0
found = False
while True:
seed=seed+1
random.seed(seed)
for i in range(1,70):
r = random.randint(0, 1000000)
if i == 69 and r == 420:
print(f"seed: {seed}")
found = True
if found:
break
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment