The file LabChapter7Problem3.txt has 100 records and is formatted as follows: Emp ID Title First Name Middle Initial Last Name Mother's Maiden Name Age in Yrs. Create a Structure with the file’s information: Employee Number, Title, First Name, Middle Initial, Last Name, Mother’s Maiden Name and Age. Sort the Structure through ascending values of the Age variable using the Enhanced Bubble Sort Algorithm Show on screen sorted records 55-65 and create a new file with all sorted records called LabChapter7Problem3SortedRecords.txt. Use the following format for both the screen output and the file created: ------------------------------------------------------------------ | Employee Number | Full Name | Age | ------------------------------------------------------------------ | 123456 | Mr. Ranma P Saotome Tendo | 21 | ------------------------------------------------------------------ | 654321 | Mr. Goku A Son Kakarot | 25 | ------------------------------------------------------------------ | 147963 | Mr. Eren W Yeager Kaiser | 27 | ------------------------------------------------------------------ (This program has to be created in C++)
The file LabChapter7Problem3.txt has 100 records and is formatted as follows:
- Emp ID
- Title
- First Name
- Middle Initial
- Last Name
- Mother's Maiden Name
- Age in Yrs.
Create a Structure with the file’s information: Employee Number, Title, First Name, Middle Initial, Last Name, Mother’s Maiden Name and Age. Sort the Structure through ascending values of the Age variable using the Enhanced Bubble Sort
Show on screen sorted records 55-65 and create a new file with all sorted records called LabChapter7Problem3SortedRecords.txt.
Use the following format for both the screen output and the file created:
------------------------------------------------------------------
| Employee Number | Full Name | Age |
------------------------------------------------------------------
| 123456 | Mr. Ranma P Saotome Tendo | 21 |
------------------------------------------------------------------
| 654321 | Mr. Goku A Son Kakarot | 25 |
------------------------------------------------------------------
| 147963 | Mr. Eren W Yeager Kaiser | 27 |
------------------------------------------------------------------
(This program has to be created in C++)
Step by step
Solved in 2 steps with 1 images