Swedenstyle34

Product Key Generator In Python 3

Jul 26th, 2021
774
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. import random
  2. chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890"
  3. while 1:
  4.     key_len = int(input("What length would you like your key to be?: "))
  5.     key_count = int(input("How many keys would you like?: "))
  6.     for x in range(0,key_count):
  7.         key = ""
  8.         for x in range(0,key_len):
  9.             key_char = random.choice(chars)
  10.             key      = key + key_charprint("Here's your key: ", key)
RAW Paste Data