def print_seconds_day (days):
hours= days*24
minutes=hours*60
seconds = minutes*60
print (seconds)
print_seconds_day(4)
def convert_days_to_seconds (days):
hours=days*24
minutes=hours*60
seconds = minutes*60
print (seconds)
return seconds
totalsec = convert_days_to_seconds (5)
millisec = totalsec*1000
print (millisec)
import random
import string
adjectives = ['sleepy', 'slow', 'hot',
'cold', 'big', 'red',
'orandge', 'yellow', 'green',
'blue', 'good', 'old',
'white', 'free', 'brave']
nouns = ['apple', 'dinosaur', 'ball', 'cat', 'goat', 'dragon', 'car', 'duck', 'panda']
print ('Добро пожаловать!')
adjective = random.choice (adjectives)
noun = random.choice (nouns)
number = random.randrange(0,100)
special_char = random.choice (string.punctuation)
password = adjective + noun + str(number) + special_char
print ('Новый пароль: %s ' % password)
import random
import string
adjectives = ['sleepy', 'slow', 'hot', 'cold', 'big',
'red', 'orandge', 'yellow', 'green',
'blue', 'good', 'old',
'white', 'free', 'brave']
nouns = ['apple', 'dinosaur', 'ball', 'cat', 'goat', 'dragon', 'car', 'duck', 'panda']
print ('Добро пожаловать!')
while True:
adjective = random.choice (adjectives)
noun = random.choice (nouns)
number = random.randrange(0,100)
special_char = random.choice (string.punctuation)
password = adjective + noun + str(number) + special_char
print ('Новый пароль: %s ' % password)
response=input ('Сгенерировать другой пароль? д/н ')
if response == 'н':
break