Advertisement
Guest User

Untitled

a guest
Mar 29th, 2017
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.20 KB | None | 0 0
  1. import random
  2. infile = open('txtfile.txt', 'w')
  3.  
  4. for i in range(int(input('How many random numbers?')))
  5. line = str(random.randint(1,500))
  6. infile.write(line)
  7. print(line)
  8.  
  9. infile.close()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement