Advertisement
Guest User

Random 5 Character String Generation

a guest
Jun 15th, 2019
112
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.33 KB | None | 0 0
  1. import os
  2. import string
  3. import random
  4.  
  5. #Created by DecstarG
  6.  
  7. i = 0
  8. string = ""
  9.  
  10. while string != "Fifty":
  11.  
  12.     chars = "qwertyuiopasdfghjklzxcvbnmQWERTYUIOPASDFGHJKLZXCVBNM"
  13.     random.seed = (os.urandom(1024))
  14.     string = ''.join(random.choice(chars) for i in range(1, 6))
  15.     print("Output number " + str(i) + ": " + string)
  16.     i = i + 1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement