Skip to content

Instantly share code, notes, and snippets.

@jamad
Last active May 31, 2024 10:53
Show Gist options
  • Save jamad/56fcf34b7fb0bf1499cfe3ab17817fd2 to your computer and use it in GitHub Desktop.
Save jamad/56fcf34b7fb0bf1499cfe3ab17817fd2 to your computer and use it in GitHub Desktop.
tmp_gist
print('helloworld')
import random
def password_gen():
s=''
s+=random.choice('abcdefghijklmnopqrstuvwxyz')
s+=random.choice('abcdefghijklmnopqrstuvwxyz'.upper())
s+=random.choice('0123456789')
for _ in range(random.randint(3,17)):
i=random.randint(1,3)
if i==1:s+=random.choice('abcdefghijklmnopqrstuvwxyz')
if i==2:s+=random.choice('abcdefghijklmnopqrstuvwxyz'.upper())
if i==3:s+=random.choice('0123456789')
return s
res=password_gen()
print(res)
@jamad
Copy link
Author

jamad commented May 31, 2024

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment