Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Please just use a simple c++ codes. What you need to do: Create a class (I call mine Employee but the exact name is not
Please just use a simple c++ codes.
What you need to do: Create a class (I call mine Employee but the exact name is not important) with the following fields: o string name oint id . int age o string job int year Your "main" program should read in a text file, the filename of which will be passed-in to your program as a command-line parameter. The file format is like so: o First line: the number of records in the file. . Every other line: Name, ID number, age, job title, hire date. Separated by vertical bars (pipes). . For each record in the file, instantiate an Employee object. Copy the data from the record into the new object. Add the new object to an array or vector. . For each object, print its information to the console in a pretty format, such as: Name: Megaboz Pibepo ID: 75534 Age: Job: Granola Taster Hire year: 1982 52 ...and so on for each record in the file. 7 Megaboz Pibepo 75534 52 | Granola Tester |1982 Gustar Woomax | 7865823 Guildmaster|1996 Orkan Thriff234398 44 Telephone Sanitizer 1987 Boswell Barwell234987|42| Biographer |1990 Fred Rogers|12345675| TV Actor|1965 Lester Victor Paper| 876922 | 49 | Criminal Mastermind 1982 Y'Gael Borphee 8728930|Talk Show Host | 2008Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started