Question: Assignment Using IntelliJ or the IDE of your choice, create a new Java application called PasswordChecker. The purpose of this application is to prompt the

Assignment

Using IntelliJ or the IDE of your choice, create a new Java application called "PasswordChecker". The purpose of this application is to prompt the user for a single word string and checks whether the String, called inputPassword, conforms to the following password policy.

Use a scanner object and prompt the user for a password that is stored in a String variable called inputPassword.

You do not need to use a loop in this program. You should be able to check each character of the password individually.

Use the Character class methods to validate whether a character is a digit or an upper cased letter.

The password must conform the the policy:

Be exactly three characters in length

Include at least one uppercase character

Include at least one digit

If validation of all three rules passes then output "The provided password is valid." If any of the rules fail then output "The provided password is invalid because it must be three characters in length and include at least one digit and at least one uppercase character. Please try again."

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!