Question: Write a C++ program that verifies that passwords satisfy the following criteria: 1) At least eight characters long 2) Contains at least one numeric digit
Write a C++ program that verifies that passwords satisfy the following criteria: 1) At least eight characters long 2) Contains at least one numeric digit 3) Contains at least one upper case and at least one lower case letter 4) Contains one of these special characters:
!@#$%&*:;
Test each criterion in a separate function.
Add a class of exception objects, with these members: member variable enumerated data type, with values corresponding to the four error types Constructor creates an object corresponding to error type member function returns a string describing the error
Write your password program as follows: In each function, construct and throw an object corresponding to the error that just occurred In the main program, embed catch all exceptions and display a message describing the first error discovered
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
