Update 'randomPwd.py'
This commit is contained in:
		
							
								
								
									
										21
									
								
								randomPwd.py
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										21
									
								
								randomPwd.py
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,21 @@
 | 
				
			|||||||
 | 
					import random
 | 
				
			||||||
 | 
					import string
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					def randomPwd(length):
 | 
				
			||||||
 | 
					    chars = string.ascii_letters + string.digits
 | 
				
			||||||
 | 
					    pwd = ''.join(random.choice(chars) for i in range(length))
 | 
				
			||||||
 | 
					    print(pwd)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# 10 Random Passwords
 | 
				
			||||||
 | 
					randomPwd(18)
 | 
				
			||||||
 | 
					randomPwd(18)
 | 
				
			||||||
 | 
					randomPwd(18)
 | 
				
			||||||
 | 
					randomPwd(18)
 | 
				
			||||||
 | 
					randomPwd(18)
 | 
				
			||||||
 | 
					randomPwd(18)
 | 
				
			||||||
 | 
					randomPwd(18)
 | 
				
			||||||
 | 
					randomPwd(18)
 | 
				
			||||||
 | 
					randomPwd(18)
 | 
				
			||||||
 | 
					randomPwd(18)
 | 
				
			||||||
 | 
					randomPwd(18)
 | 
				
			||||||
 | 
					#######################
 | 
				
			||||||
@@ -1,20 +0,0 @@
 | 
				
			|||||||
import random
 | 
					 | 
				
			||||||
import string
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
def random_password(length):
 | 
					 | 
				
			||||||
    chars = string.ascii_letters + string.digits
 | 
					 | 
				
			||||||
    password = ''.join(random.choice(chars) for i in range(length))
 | 
					 | 
				
			||||||
    print(password)
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
random_password(18)
 | 
					 | 
				
			||||||
random_password(18)
 | 
					 | 
				
			||||||
random_password(18)
 | 
					 | 
				
			||||||
random_password(18)
 | 
					 | 
				
			||||||
random_password(18)
 | 
					 | 
				
			||||||
random_password(18)
 | 
					 | 
				
			||||||
random_password(18)
 | 
					 | 
				
			||||||
random_password(18)
 | 
					 | 
				
			||||||
random_password(18)
 | 
					 | 
				
			||||||
random_password(18)
 | 
					 | 
				
			||||||
random_password(18)
 | 
					 | 
				
			||||||
		Reference in New Issue
	
	Block a user