Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 8 additions & 3 deletions src/main.py
Original file line number Diff line number Diff line change
@@ -1,15 +1,20 @@
# Resolve the problem!!
import string
import random

SYMBOLS = list('!"#$%&\'()*+,-./:;?@[]^_`{|}~')
LETTERS = list(string.ascii_letters)
NUMBERS = list(string.digits)
character_list = SYMBOLS + LETTERS + NUMBERS
lenght_password = random.randint(8,16)


def generate_password():
# Start coding here

passcode = random.sample(character_list,lenght_password)
password = ''.join(map(str,passcode))
return password

def validate(password):

if len(password) >= 8 and len(password) <= 16:
has_lowercase_letters = False
has_numbers = False
Expand Down