Skip to content

Instantly share code, notes, and snippets.

@4383
Created Mar 29, 2018
Embed
What would you like to do?
Minify url algorithme with python
import random
choices = range(48, 57)
choices.extend(range(65, 90))
choices.extend(range(97, 122))
chr_identifier = ""
int_identifier = ""
for el in range(0, 6):
chr_identifier += chr(random.choice(choices))
int_identifier += str(random.choice(choices))
print(chr_identifier)
print(int_identifier)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment