Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write a C++ program that does the following: -Ask the user for an input file name -Read the data from the file and place it

Write a C++ program that does the following:

-Ask the user for an input file name

-Read the data from the file and place it in the array of structures

-Data will contain the following: job description, number of skills (int) followed by 'n' lines each listing a skill, followed by salary, followed by company name - all on separate lines. Assume all string data will have less than 256 characters. There will never be more than 10 job skills. There will not be extra white space in the input file. If there is a job title on one line, the following lines of data for that job are guaranteed to exist. Job titles, skills and company names may all be comprised of more than one word (use getline).

SAMPLE FILE DATA:

image text in transcribed

Program must be able to handle at most data on 10 jobs, but the input file may have more or less entries in it. If the input file has too many entries in it, just don't read them (dont go out-of-bounds in your array). If the input file has too few, partially fill your array of structures

-After reading the job data into the array of structures, print the following menu for the user:

1) Search for a job by skill

2) Search for a job by title

3) Quit

-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.

-If the user chooses option 2, Search for a 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

file information: image text in transcribed
Web Developer PHP HTML CSS Javascript jQuery JSON SOL 60000 Knox County Government Systems Operations Programming - Student SOL PLC programming 31000 Knoxville Utilities Board The application asks the user for an input file name. The contents of a sample input file with two jobs is shown below. One job consists of a line with the job description followed by a line with the number of job skills desired, n, followed by n lines each listing a skill, followed by a salary followed by a company name - all on separate lines. Assume all string data will have less than 256 characters. There will never be more than 10 job skills. There will not be extra white space in the input file. If there is a job title on one line, the following lines of data for that job are guaranteed to exist. Job titles, skills and company names may all be comprised of more than one word (use getline). Web Developer PHP HTML CSS Javascript jQuery JSON SOL 60000 Knox County Government Systems Operations Programming - Student SQL PLC programming 31000 Knoxville Utilities Board Your program must be able to handle at most data on 10 jobs, but the input file may have more or less entries in it. If the input file has too many entries in it, just don't read them (don't go out-of-bounds in your array). If the input file has too few, partially fill your array of structures.... The program reads in the data from the input file and puts it into an array of structures. The structure MUST use C-strings for the job description, skills and company name. Web Developer PHP HTML CSS Javascript jQuery JSON SOL 60000 Knox County Government Systems Operations Programming - Student SOL PLC programming 31000 Knoxville Utilities Board The application asks the user for an input file name. The contents of a sample input file with two jobs is shown below. One job consists of a line with the job description followed by a line with the number of job skills desired, n, followed by n lines each listing a skill, followed by a salary followed by a company name - all on separate lines. Assume all string data will have less than 256 characters. There will never be more than 10 job skills. There will not be extra white space in the input file. If there is a job title on one line, the following lines of data for that job are guaranteed to exist. Job titles, skills and company names may all be comprised of more than one word (use getline). Web Developer PHP HTML CSS Javascript jQuery JSON SOL 60000 Knox County Government Systems Operations Programming - Student SQL PLC programming 31000 Knoxville Utilities Board Your program must be able to handle at most data on 10 jobs, but the input file may have more or less entries in it. If the input file has too many entries in it, just don't read them (don't go out-of-bounds in your array). If the input file has too few, partially fill your array of structures.... The program reads in the data from the input file and puts it into an array of structures. The structure MUST use C-strings for the job description, skills and company name

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

The Manga Guide To Databases

Authors: Mana Takahashi, Shoko Azuma, Co Ltd Trend

1st Edition

1593271905, 978-1593271909

More Books

Students also viewed these Databases questions

Question

Calculate G at 300 and 390 K for the following reactions.

Answered: 1 week ago