Hey guys, im having trouble with this code. Basically i have a text file with employee id numbers and their names next to them (ex: 8379192 Sean). I am asked to create the following:
Write a program to that allows the user to input a name from the keyboard. The program should then read from the file and search for matching name among the employees. If a match is found it should output the name/names with the ID/IDs and the total number of employee/employees in you program. The program should also indicate if there is no match (see Figure4).
You program also must account for the following scenarios:
• Your program cannot open the data file. Figure1 illustrates the expected behavior.
• Your program should also display the total number of employee(s) found after searching.
• If there is only one employee found, your program should display “There is only 1
employee found from the employee list.”; If there are x (x>1) employees found, your program should display “There are x employees found from the employee list.”. Figure 2 & 3 illustrate the expected behaviors.
Hint: You can edit your post, highlight your code and press the <> formatting button.
You can use the preview button at the bottom to see how it looks.
I found the second link to be the most help.
Do not edit your OP with updates. Post them in a new message.
When you post the code that you have you can get a better answer.