Question: Write a C++ program that does the following: You are given an input file with the following job data, sorted by job. Each job will
Write a C++ program that does the following: You are given an input file with the following job data, sorted by job. Each job will contain the following lines:
-First line: Job description (string)
-Second line: number of skills (int)
-Followed by: 'n' lines each listing a skill (string)
-Followed by: Salary (int)
-Last line: Company name (string)
EXAMPLE FILE DATA:
Web Developer
7
PHP
HTML
CSS
Javascript
jQuery
JSON
SQL
60000
Google Internship
Systems Operations Programming - Student
2
SQL
PLC programming
31000
Knoxville Utilities Board
Write a C++ program that performs two searches, one searches for a job by skill and the other searches for a job by title.
If the user chooses option 1. Search for a job by skill, ask the user for the skill and print the job title, salary and company of all job postings that require that skill in a neatly formatted table as shown below in alphabetical order by job description. Search for any skill that starts with the search term, ignoring case for the job skill. Job skill: SQL Job Title Salary Company - -- - - - -- - - - -- - - - -- - - - -- - - - -- - - - -- - - - -- - - - -- - - - -- - - - -- - - - -- - - - -- - - - -- - - - -- $ 31000 Knoxville Utilities Board $ 60000 Knox County Government Systems Operations Programming - Student SQL PLC Programming Web Developer PHP HTML CSS Javascript jQuery JSON SQL If the user chooses option 2. Search for job by title, ask the user for job title and print a neatly formatted table of all jobs with that word in the title (case-insensitive) in alphabetical order by job title such as: Job title: developer Job Title Salary Company $ 60000 Knox County Government Web Developer PHP HTML CSS Javascript jQuery JSON SOL If the user chooses option 1. Search for a job by skill, ask the user for the skill and print the job title, salary and company of all job postings that require that skill in a neatly formatted table as shown below in alphabetical order by job description. Search for any skill that starts with the search term, ignoring case for the job skill. Job skill: SQL Job Title Salary Company - -- - - - -- - - - -- - - - -- - - - -- - - - -- - - - -- - - - -- - - - -- - - - -- - - - -- - - - -- - - - -- - - - -- - - - -- $ 31000 Knoxville Utilities Board $ 60000 Knox County Government Systems Operations Programming - Student SQL PLC Programming Web Developer PHP HTML CSS Javascript jQuery JSON SQL If the user chooses option 2. Search for job by title, ask the user for job title and print a neatly formatted table of all jobs with that word in the title (case-insensitive) in alphabetical order by job title such as: Job title: developer Job Title Salary Company $ 60000 Knox County Government Web Developer PHP HTML CSS Javascript jQuery JSON SOL
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
