Question: Sorting Positions and Salaries Bubble Sorting Assignment The data file careers.txt contains a list of job titles and average annual salaries, such as: Computer and
Sorting Positions and Salaries
Bubble Sorting Assignment
The data file careers.txt contains a list of job titles and average annual salaries, such as:
Computer and Information Research Scientists
Computer and Information Analysts
Computer Systems Analysts
Information Security Analysts
Every two lines can be interpreted as a single logical record for a job position
The file has real data from the US Department of Labors May survey of occupations and wages. In this exercise you should create two parallel arrays, one for job and one for salary, and read data from the file into the arrays one line into the job array and then one line into the corresponding element in the salary array. Your program should sort the lists in parallel according to the values in the salary array, with the highest salary first. Sorting in parallel means that in your sort, if you swap two elements in the salary array, you must also swap the corresponding elements in the job array.
Your program should then display and print the list of jobs and corresponding salaries on the screen in a neatly formatted table, with comas in the salaries.. Use print Specifiers or formatting Classes in Java to format the output.
Submit a Lab Report for this assignment
Submit a zipped intellj Project Folder containing the assignment resources
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
