STL ARRAYLIST Array List The Dancing Champs institution is organizing a dance competition for kids. The competition will have various levels and batches and can go on for a full day. They do not have enough space to accommodate so many dancers in their institute so they book a banquet with many halls. Initially, the number of performances is fixed but can increase later and even hall allotment can be revised as well. So they can replace/remove data from any hall at any time. You are the accommodation head of the institute and need to propose a plan so that you can hire halls anytime. Ask the Institute for the initial number of performances then display the menu as described in input and output format. Write a C++ program to add new details in the existing ArrayList and to remove details from the ArrayList. Use Menu to add, remove and display the Hall details. Strictly adhere to the Object-Oriented specifications given in the problem statement. All class names, member variable names and function names should be the same as specified in the problem statement. Create Hall class with private member variables Data type Variables string name int contactNumber double costPerDay string ownerName Include appropriate getters, and setters and constructor (name,contactNumber,costPerDay,ownerName) in this order for the Hall class. Include following public member function in Hall class Method Name Description list getHallDetails() This method is used to return the hall details. [Hall details are already pre-populated in the template code] Create HallBO class and include following member function Method Name Description bool contains(list halls, string hallName ) This function is used to compare whether the hall list contains that hall name. If the hall name presents it returns true to remove that name otherwise it returns false. void display(list halls) This function is used to display the list of halls along with hardcoded details. Use "%-25s%-25d%-25.2f%-25s\n" to print table the details. In the main method test the above class and print the string "Hall Details:" in the main method itself Input and Output format: Print the costPerDay with two decimal values. Refer sample input and output for formatting specifications. [All text in bold corresponds to input and the rest corresponds to output] Sample Input and Output 1: 1.Add 2.Remove 3.Display Enter your choice 3 Hall Details: Hall Name Contact Number Cost Owner Chiltington 1798888137 30000.00 Robert Kilmersdon 1761436767 22000.00 James Press 1 to continue 2 Sample Input and Output 2: 1.Add 2.Remove 3.Display Enter your choice 1 Enter the details of Hall Hall Name : Mahal Contact Number : 1761436007 Cost per day : 22000 Owner Name : Akshay Press 1 to continue 1 1.Add 2.Remove 3.Display Enter your choice 1 Enter the details of Hall Hall Name : Manor Contact Number : 1515232061 Cost per day : 25000 Owner Name : Jack Press 1 to continue 1 1.Add 2.Remove 3.Display Enter your choice 3 Hall Details: Hall Name Contact Number Cost Owner Mahal 1761436007 22000.00 Akshay Manor 1515232061 25000.00 Jack Chiltington 1798888137 30000.00 Robert Kilmersdon 1761436767 22000.00 James Press 1 to continue 1 1.Add 2.Remove 3.Display Enter your choice 2 Enter the Hall name to be removed Kilmersdon Press 1 to continue 1 1.Add 2.Remove 3.Display Enter your choice 3 Hall Details: Hall Name Contact Number Cost Owner Mahal 1761436007 22000.00 Akshay Manor 1515232061 25000.00 Jack Chiltington 1798888137 30000.00 Robert Press 1 to continue 2
STL ARRAYLIST Array List The Dancing Champs institution is organizing a dance competition for kids. The competition will have various levels and batches and can go on for a full day. They do not have enough space to accommodate so many dancers in their institute so they book a banquet with many halls. Initially, the number of performances is fixed but can increase later and even hall allotment can be revised as well. So they can replace/remove data from any hall at any time. You are the accommodation head of the institute and need to propose a plan so that you can hire halls anytime. Ask the Institute for the initial number of performances then display the menu as described in input and output format. Write a C++ program to add new details in the existing ArrayList and to remove details from the ArrayList. Use Menu to add, remove and display the Hall details. Strictly adhere to the Object-Oriented specifications given in the problem statement. All class names, member variable names and function names should be the same as specified in the problem statement. Create Hall class with private member variables Data type Variables string name int contactNumber double costPerDay string ownerName Include appropriate getters, and setters and constructor (name,contactNumber,costPerDay,ownerName) in this order for the Hall class. Include following public member function in Hall class Method Name Description list getHallDetails() This method is used to return the hall details. [Hall details are already pre-populated in the template code] Create HallBO class and include following member function Method Name Description bool contains(list halls, string hallName ) This function is used to compare whether the hall list contains that hall name. If the hall name presents it returns true to remove that name otherwise it returns false. void display(list halls) This function is used to display the list of halls along with hardcoded details. Use "%-25s%-25d%-25.2f%-25s\n" to print table the details. In the main method test the above class and print the string "Hall Details:" in the main method itself Input and Output format: Print the costPerDay with two decimal values. Refer sample input and output for formatting specifications. [All text in bold corresponds to input and the rest corresponds to output] Sample Input and Output 1: 1.Add 2.Remove 3.Display Enter your choice 3 Hall Details: Hall Name Contact Number Cost Owner Chiltington 1798888137 30000.00 Robert Kilmersdon 1761436767 22000.00 James Press 1 to continue 2 Sample Input and Output 2: 1.Add 2.Remove 3.Display Enter your choice 1 Enter the details of Hall Hall Name : Mahal Contact Number : 1761436007 Cost per day : 22000 Owner Name : Akshay Press 1 to continue 1 1.Add 2.Remove 3.Display Enter your choice 1 Enter the details of Hall Hall Name : Manor Contact Number : 1515232061 Cost per day : 25000 Owner Name : Jack Press 1 to continue 1 1.Add 2.Remove 3.Display Enter your choice 3 Hall Details: Hall Name Contact Number Cost Owner Mahal 1761436007 22000.00 Akshay Manor 1515232061 25000.00 Jack Chiltington 1798888137 30000.00 Robert Kilmersdon 1761436767 22000.00 James Press 1 to continue 1 1.Add 2.Remove 3.Display Enter your choice 2 Enter the Hall name to be removed Kilmersdon Press 1 to continue 1 1.Add 2.Remove 3.Display Enter your choice 3 Hall Details: Hall Name Contact Number Cost Owner Mahal 1761436007 22000.00 Akshay Manor 1515232061 25000.00 Jack Chiltington 1798888137 30000.00 Robert Press 1 to continue 2
Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
Related questions
Question
STL ARRAYLIST
Array List
The Dancing Champs institution is organizing a dance competition for kids. The competition will have various levels and batches and can go on for a full day. They do not have enough space to accommodate so many dancers in their institute so they book a banquet with many halls. Initially, the number of performances is fixed but can increase later and even hall allotment can be revised as well. So they can replace/remove data from any hall at any time. You are the accommodation head of the institute and need to propose a plan so that you can hire halls anytime. Ask the Institute for the initial number of performances then display the menu as described in input and output format.
Write a C++ program to add new details in the existing ArrayList and to remove details from the ArrayList. Use Menu to add, remove and display the Hall details.
Strictly adhere to the Object-Oriented specifications given in the problem statement. All class names, member variable names and function names should be the same as specified in the problem statement.
Create Hall class with private member variables
Data type | Variables |
string | name |
int | contactNumber |
double | costPerDay |
string | ownerName |
Include appropriate getters, and setters and constructor (name,contactNumber,costPerDay,ownerName) in this order for the Hall class.
Include following public member function in Hall class
Method Name | Description |
list<Hall> getHallDetails() | This method is used to return the hall details. [Hall details are already pre-populated in the template code] |
Create HallBO class and include following member function
Method Name | Description |
bool contains(list <Hall> halls, string hallName ) | This function is used to compare whether the hall list contains that hall name. If the hall name presents it returns true to remove that name otherwise it returns false. |
void display(list<Hall> halls) | This function is used to display the list of halls along with hardcoded details. Use "%-25s%-25d%-25.2f%-25s\n" to print table the details. |
In the main method test the above class and print the string "Hall Details:" in the main method itself
Input and Output format:
Print the costPerDay with two decimal values.
Refer sample input and output for formatting specifications.
[All text in bold corresponds to input and the rest corresponds to output]
Sample Input and Output 1:
Sample Input and Output 1:
1.Add
2.Remove
3.Display
Enter your choice
3
Hall Details:
Hall Name Contact Number Cost Owner
Chiltington 1798888137 30000.00 Robert
Kilmersdon 1761436767 22000.00 James
Press 1 to continue
2
Sample Input and Output 2:
1.Add
1.Add
2.Remove
3.Display
Enter your choice
1
Enter the details of Hall
Hall Name :
Mahal
Contact Number :
1761436007
Cost per day :
22000
Owner Name :
Akshay
Press 1 to continue
1
1.Add
2.Remove
3.Display
Enter your choice
1
Enter the details of Hall
Hall Name :
Manor
Contact Number :
1515232061
Cost per day :
25000
Owner Name :
Jack
Press 1 to continue
1
1.Add
2.Remove
3.Display
Enter your choice
3
Hall Details:
Hall Details:
Hall Name Contact Number Cost Owner
Mahal 1761436007 22000.00 Akshay
Manor 1515232061 25000.00 Jack
Chiltington 1798888137 30000.00 Robert
Kilmersdon 1761436767 22000.00 James
Press 1 to continue
1
1.Add
2.Remove
3.Display
Enter your choice
2
Enter the Hall name to be removed
Kilmersdon
Press 1 to continue
1
1.Add
2.Remove
3.Display
Enter your choice
3
Hall Details:
Hall Details:
Hall Name Contact Number Cost Owner
Mahal 1761436007 22000.00 Akshay
Manor 1515232061 25000.00 Jack
Chiltington 1798888137 30000.00 Robert
Press 1 to continue
2
Expert Solution
This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
This is a popular solution!
Trending now
This is a popular solution!
Step by step
Solved in 8 steps with 4 images
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY