Question: Social Security Number Validation ( 1 0 points ) : You will be writing a program that takes in a list of social security numbers

Social Security Number Validation (10 points): You will be writing a program that takes
in a list of social security numbers from the user and after the list has been completely
entered, it validates the answers. Please submit your final Python program and PDF
copy of it via the D2L Dropbox for Assignment 2.
For this program, we will be utilizing many concepts such as lists, Boolean values,
iteration, user input, and formatting in an effort to review early python concepts. A sample
run of the program is shown below, but this program should:
Ask the user to enter social security numbers one at a time until they type some variation
of 'done' (i.e., 'done', 'DONE', 'dOnE', 'doNE', etc... use a string method for this!
The . lower and . upper methods should work nicely).
For every candidate social security number (SSN) entered by the user, the program
should use a function called isvalidSSN () to check the validity of the entered SSN.
This isvalidSSN () function should check the SSN is (1) the valid length, (2) has the
hyphens in the right places, and (3) that all the values other than hyphens are digits. Once these
checks are done, isvalidSSN () should return a 2 element list consisting of the candidate
SSN and a Boolean value describing its validity (e.g.['22a-22-2222', False]).
The program should use the results of calling isvalidSSN () for each candidate
social security number to build a list of lists of all the candidate SSNs and their validity
(e.g.[['111-11-1111', True],['22a-22-2222', False]])). This list of
lists should be printed into a nicely formatted table using f-strings or the format method.
This string formatting should be done in main(). Formatting Strings Help: See
Section 9.2 of your textbook for a refresher on format method and Section 9.11 for f-
 Social Security Number Validation (10 points): You will be writing a

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!