Write a C++ program that creates a linked list of Course data. Each entry in the list is to have the course number such as "CPL510" and its course title such as "Data Structures and Algorithms", and a pointer to the next computer data. Create a Then create a pointer (“head”) that points to the first element in the linked list (initially NULL). Also, you need to create the following methods in the LinkedList class (within LinkedList.h file):
Course Number: CPL120
Course Title: Programming for Computer Engineering
Course Number: CPL340
Course Title: Intro to Programming Languages
Course Number: CPL510
Course Title: Data Structures and Algorithms
Course Number: MAT123
Course Title: Discrete Math Structures
Choicett Actionn
------tt ------n
Att Add Coursen
Dtt Display Coursesn
Qtt Quitn
Rtt Remove Coursen
? tt Display Helpnn
Next, the following prompt should be displayed:
What action would you like to perform?n
Read in the user input and execute the appropriate command. After the execution of each command, redisplay the prompt. Commands should be accepted in both lowercase and uppercase.
The following is an example run (user input is in bold letter):
Choice Action
------ ------
A Add Course
D Display Courses
Q Quit
R Remove Course
? Display Help
What action would you like to perform?
A
Please enter a course information:
Enter a course number:
CPL510
Enter a course title:
Data Structures and Algorithms
The course CPL510 added
What action would you like to perform?
D
Course Number: CPL510
Course Title: Data Structures and Algorithms
What action would you like to perform?
A
Please enter a course information:
Enter a course number:
CPL340
Enter a course title:
Intro to Programming Languages
The course CPL340 added
What action would you like to perform?
A
Please enter a course information:
Enter a course number:
CPL120
Enter a course title:
Programming for Computer Engineering
The course CPL120 added
What action would you like to perform?
D
Course Number: CPL120
Course Title: Programming for Computer Engineering
Course Number: CPL340
Course Title: Intro to Programming Languages
Course Number: CPL510
Course Title: Data Structures and Algorithms
What action would you like to perform?
A
Please enter a course information:
Enter a course number:
CPL340
Enter a course title:
Intro to C++
The course CPL340 exists
What action would you like to perform?
D
Course Number: CPL120
Course Title: Programming for Computer Engineering
Course Number: CPL340
Course Title: Intro to Programming Languages
Course Number: CPL510
Course Title: Data Structures and Algorithms
What action would you like to perform?
A
Please enter a course information:
Enter a course number:
MAT123
Enter a course title:
Discrete Math Structures
The course MAT123 added
What action would you like to perform?
A
Please enter a course information:
Enter a course number:
MAT300
Enter a course title:
Mathematical Structures
The course MAT300 added
What action would you like to perform?
D
Course Number: CPL120
Course Title: Programming for Computer Engineering
Course Number: CPL340
Course Title: Intro to Programming Languages
Course Number: CPL510
Course Title: Data Structures and Algorithms
Course Number: MAT123
Course Title: Discrete Math Structures
Course Number: MAT300
Course Title: Mathematical Structures
What action would you like to perform?
R
Please enter a course number to remove:
MAT242
The course MAT242 does not exist
What action would you like to perform?
D
Course Number: CPL120
Course Title: Programming for Computer Engineering
Course Number: CPL340
Course Title: Intro to Programming Languages
Course Number: CPL510
Course Title: Data Structures and Algorithms
Course Number: MAT123
Course Title: Discrete Math Structures
Course Number: MAT300
Course Title: Mathematical Structures
What action would you like to perform?
R
Please enter a course number to remove:
CPL340
The course CPL340 removed
What action would you like to perform?
D
Course Number: CPL120
Course Title: Programming for Computer Engineering
Course Number: CPL510
Course Title: Data Structures and Algorithms
Course Number: MAT123
Course Title: Discrete Math Structures
Course Number: MAT300
Course Title: Mathematical Structures
What action would you like to perform?
Q
The number of deleted courses is: 4