import random A = random.randint(0,10) k = (x for x in range(10)) for num in k: print(num) if num == A: break
To embed this project on your website, copy the following code and paste it into your website's HTML: