18 Answers
+ 3
Password maker?
Password validator?
What kind of password code?
Have you tried searching the Codes section? I'd go there first when I need an example, or inspiration ...
+ 2
Like this
Password is 2994
1 2 3
4 5 6
7 8 9
+ 2
What did you mean "click"? are you into making a GUI app? if you want GUI, then web code is the way to go cause only web code supports GUI here.
+ 2
Pasword Validation
Good luck!
https://code.sololearn.com/cSIvWQT7fPDd/?ref=app
Password Generator
https://code.sololearn.com/cvS8raRx4Apb/?ref=app
+ 2
Create a content store it , then whenever there is an input check if that input correspond to the stored value.
+ 1
Please elaborate what you want to do
+ 1
And click
+ 1
Hmmm , i think you are taking about the getpass module
It is a module that allows user to enter hidden input
import getpass
x = getpass.getpass()
+ 1
You mean password generator??
Here
import string
from random import *
letters = string.ascii_letters
digits = string.digits
symbols = string.punctuation
chars = letters + digits + symbols
min_length = 8
max_length = 16
password = "".join(choice(chars) for x in range(randint(min_length, max_length)))
print(password)
credit-sololearn
or
import random
password =""
for i in range(12):
password += random.choice(list("1234567890qwertyuiopasdfghjklzxcvbnmQWERTYUIOPASDFGHJKLZXCVBNM@#$%&*-=()!"':;/?~±×÷•°`´{}©£€^®¥_+[]¡<>¢|\¿]}'")"))
print(password)
+ 1
Question not clear
Do you want to collect password from user as input and compare it with what you have in your database
+ 1
Can you describe more that we can understand what you want actually?
+ 1
How can I solve
+ 1
Like this
For example password is 1111,
1 2 3
4 5 6
7 8 9
And click 1,1,1,1 ,become unlocked.
0
This can't make with Python?
0
from getpass import getpass
name = input('Name:')
password= getpass('Password:')
0
Sololearn not import GUI so first download "Pydroid 3" from Google play store and learn GUI program.
Run this program.
from tkinter import *
#defining login function
def login():
uname=username.get()
pwd=password.get()
if uname=='' or pwd=='' message.set("fill the empty field!!!")
else: if uname=="abcd@gmail.com" and pwd=="abc123":
message.set("Login success")
else:
message.set("Wrong username or password!!!")
#defining loginform function
def Loginform():
global login_screen
login_screen = Tk()
#Setting title of screen
login_screen.title("Login Form")
#setting height and width of screen
login_screen.geometry("300x250")
#declaring variable
global message;
global username
global password
username = StringVar()
password = StringVar()
message=StringVar()
#Creating layout of login form
Label(login_screen,width="300", text="Please enter details below", bg="orange",fg="white").pack()
Label(login_screen, text="")
0
Yes