Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Write a program that requests a password and verifies that it is a valid
- password. To be valid the password must be at least 6 characters long and
- contain at least one digit.
- Your program should:
- 1. Determine whether the password is valid. If it is not, a message telling
- the user what is wrong should be output
- 2. If it is valid, the program should thank the user for entering a valid
- password
- Once your program executes correctly, upload your file. Make sure
- your name is in a comment.
- Sample Output (inputs in bold)
- Please enter a password: pass6
- Passwords must be at least 6 characters long
- Please enter a password: TarrantNW
- Passwords must include at least one digit (1-9)
- Please enter a password: Tccd03
- Thank you, that is a valid password
Advertisement
Add Comment
Please, Sign In to add comment