This lab depends on lab5 being completed. Because many students did not finish last week, you may complete lab5 and have it graded by the TA in this week's lab, during the first hour only.
Note that the program must be written, compiled, and executed under Linux.
Create a directory called lab6 using the mkdir command and copy your files from lab5 into this directory using the cp command.
Once you have done this, add a public method called setName that can be called to set a person's name. The method should take an array of characters as a parameter and use the strdup function to store a copy of the array to the name variable. The function does not need to return a value.
Finally, modify the print method to print the social security number and the name.
Following is a partial sample run.
This program will allow you to enter in social security numbers and names,
then allow you to search for a social security number given the last 4 digits.
Please enter a SSN for person 1: 555-55-5555
Please enter a name for person 1: John Doe
.
.
.
Please enter a SSN for person 10: 555-555-5555
That SSN is not valid. Please try again.
Please enter a SSN for person 10: 444-44-5555
Please enter a name for person 10: Jane Doe
Here is a list of all of the SSNs and names entered:
555-55-5555 John Doe
.
.
.
444-44-5555 Jane Doe
Please enter the last 4 digits of an SSN to search for: 5555
The following person(s) match:
555-55-5555 John Doe
444-44-5555 Jane Doe