“generator losowych haseł w Python” Kod odpowiedzi

Generator hasła Python

import string
from random import *
characters = string.ascii_letters + string.punctuation  + string.digits
password =  "".join(choice(characters) for x in range(randint(8, 16)))
print password
Glorious Giraffe

Generator haseł Python

import random

lower = "abcdefghijklmnopqrstuvwxyz"
upper = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
numbers = "0123456789"
symbols = "@#$&_-()=%*:/!?+."


string = lower + upper + numbers + symbols
length = int(input("How Many Characters Do You Want Your Password To Be: "))
password = "".join(random.sample(string, length))

print("Here Is Your Password:", password)
Sleepy Skimmer

Generator hasła w Python

import random

strong_keys = ["@","#","$","£","π","¥","&","3","¢","3","*","?","!","%","/","G","A","B","F","W","F","H","6","9",":","^","=","|","~","∆"]

def password():
	try:
		n = int(input('your password contain(type in number) : '))
	except:
		print('Rerun the program and type in number please')

	ans = ""
	for i in range(n):
		rand = random.choice(strong_keys)
		if i == 0:
			ans = rand
		else:
			ans += rand
		
	print('\n\nyour password: '+ans+'\n\n')
	user = input('if you dont like this?\nType \"r\" else \"q\" : ')
	if user.lower() == 'r':
		password()
	else:
		quit()
	
password()
S UZAIR

Generator hasła Python

from random import randint

def create_random_chars(nbr_of_chars):
    return "".join(chr(randint(33,126)) for i in range(nbr_of_chars))


print(create_random_chars(10))
# I1CU>E5q;$
Puzzled Penguin

generator losowych haseł w Python

123455
Pleasant Pollan

Odpowiedzi podobne do “generator losowych haseł w Python”

Pytania podobne do “generator losowych haseł w Python”

Więcej pokrewnych odpowiedzi na “generator losowych haseł w Python” w Python

Przeglądaj popularne odpowiedzi na kod według języka

Przeglądaj inne języki kodu