Skip to content

Instantly share code, notes, and snippets.

@Mr-Fox-h
Created January 11, 2022 13:18
Show Gist options
  • Save Mr-Fox-h/6b282e2e9538c90abb48dff075ccc507 to your computer and use it in GitHub Desktop.
Save Mr-Fox-h/6b282e2e9538c90abb48dff075ccc507 to your computer and use it in GitHub Desktop.
Make random password in Python
import random
from typing import Counter
"""
Make random password in python
You can make password Whatever you want!
"""
Lower_C = "abcdefghijklmnopqrstuvwxyz"
Upper_C = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
Numbers = "0123456789"
Symbols = "[]{}()*;/,._-+\'\"?%/"
all = Lower_C + Upper_C + Numbers + Symbols
### Puts A Number In Counter ###
Counter = int(input("How many?: "))
Secret_Fox = "".join(random.sample(all, Counter))
### Print Password ###
print("Your password: " + Secret_Fox)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment