Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

validity of password in python

# Python program to check validation of password
# Module of regular expression is used with search()
import re
password = "R@m@_f0rtu9e$"
flag = 0
while True:  
    if (len(password)<8):
        flag = -1
        break
    elif not re.search("[a-z]", password):
        flag = -1
        break
    elif not re.search("[A-Z]", password):
        flag = -1
        break
    elif not re.search("[0-9]", password):
        flag = -1
        break
    elif not re.search("[_@$]", password):
        flag = -1
        break
    elif re.search("s", password):
        flag = -1
        break
    else:
        flag = 0
        print("Valid Password")
        break
  
if flag ==-1:
    print("Not a Valid Password")
Comment

password validation in python

pw=input()
pwv=input()
while pwv != pw :
	pwv=input()
Comment

PREVIOUS NEXT
Code Example
Python :: showing typle results with for loop in py 
Python :: how to identify set list and tuple in python 
Python :: groupby sum and mean 2 columns 
Python :: double digest fasta files 
Python :: list devices python 3 
Python :: python recase 
Python :: is reversed a generator python 
Python :: refresh tab selenium python 
Python :: is 2 an even number 
Python :: regex library with def (apply , lambda) 
Python :: How to know position on Kivy 
Python :: print all data in excel openpyxl 
Python :: What is shadows built in name? 
Python :: dict pop with index python 
Python :: sort vs sorted python 
Python :: django query column 
Python :: parse tree tags 
Python :: np.apply_along_axis third dimension python 
Python :: islink(node1 node2) is used for 
Python :: python how to request query string korean encode 
Python :: how to fix invalid salt in python flask 
Python :: cbv uk django 
Python :: bar chart with x-ticks 
Python :: equivalent of spread in R in python 
Python :: python code to print fibonacci series 
Python :: display full length jupyter 
Python :: how to read xlsx file from one directory above python 
Python :: who is agada nathan 
Python :: mechanize python #11 
Python :: Local to ISO 8601 without microsecond: 
ADD CONTENT
Topic
Content
Source link
Name
7+7 =