Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Create random string in Python
import random
import string
length=10
code = ''.join(random.choice(string.ascii_uppercase + string.digits) for _ in range(length))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment