Question: Write a Python function, which takes no arguments on input, that is capable of generating and printing to screen a random password that is 8

Write a Python function, which takes no arguments on input, that is capable of generating and printing to screen a random password that is 8 characters long. Specifically, each password consists of 6 letters and 2 digits, not necessarily in that order. For the sake of simplicity, the characters in the password can only be a,b,c,d,e,f,g,h,i,j and digits 1,2,3,4,5. In addition, one of the letters must appear as a capital letter and it must appear at random spots when a new password is generated, i.e. it cannot have a fixed spot. All other letters must remain lower case and each letter, capitalized or not, can only occur once. For example, E and e cannot both occur in the password. The digits must also occur only once. Some examples of passwords are: jF4bga5d or 3agbh2Ec.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!