Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- username = input("please enter user name: ")
- password = input("please enter password: ")
- def wholestring(stuff):
- str.isalnum(stuff)
- def validate(username, password):
- if username == password:
- return False
- passlength = len(password)
- if passlength < 8:
- return False
- wholestring(password)
- wholestring(username)
- def main():
- if validate(username,password) == True:
- print("Password is valid")
- else:
- print("Password is invalid")
- main()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement