Created
March 17, 2023 20:36
-
-
Save makesomelayouts/a9b2bd2e16989bde8ac6a0452623f55b to your computer and use it in GitHub Desktop.
last print() is string of shuffle random ascii letters with digits in 12 length.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import secrets | |
| import string | |
| print(f'ascii_letters {string.ascii_letters}') | |
| print(f'ascii_lowercase {string.ascii_lowercase}') | |
| print(f'ascii_uppercase {string.ascii_uppercase}') | |
| print(f'digits {string.digits}') | |
| print(f'punctuation {string.punctuation}') | |
| all_chars = string.ascii_letters + string.digits | |
| print(''.join(secrets.choice(all_chars) for _ in range(12))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment