Program Python untuk membaca baris acak dari file
import random
def randnum(fname):
with open(fname).read().splitlines() as
print(lines)
return random.choice(lines)
print(randnum('file1.txt'))
Man