Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

For the Amusement park class can you use a vector I think I know how to solve it with a pointer? Amusement parks have minimum

image text in transcribed

For the Amusement park class can you use a vector I think I know how to solve it with a pointer?

Amusement parks have minimum heights for their rides. Create a program that adds users to the line of a ride in an amusement park if they meet the minimum height requirement (given in inches). . Create three classes: o An amusement park class o A ride class (an actual ride in the amusement park) o Arider class (people riding the rides) It should work with the following main (DO NOT MODIFY-NO CREDIT IF YOU MODIFY): int main0 Rider ri Yaris.45):/ame, height in inches Rider r2(49): //height in inches Amusement park a13)://3 is the number of rides in the amusement park alget ride(1)add line(rl): //add a rider to the line of a ride Amusement park a2(2)://2 is the number of rides in the amusement park a2 get ride(1).add line(r2)://add a rider to the line of a ride return 0: Note Amusement park a1(3): 3 is the number of rides in the amusement park al. get,ride(1) add inerl):/add a rider to the line of a ride The integer angument in the function get,ride( 1) represents the number of the ride (Is it ride 17 ride 2? ride 37) in the amasement park For example, al has 3 rides, so the number we pass in is the number of the ride to add a rider to (ride 1 in this case) Amusement Park Info Ride 1- Enter minimum ride height and ride name: 40 ridel Ride 2-Enter minimum ride height and ride name: 50 ride2 Ride 3- Enter minimum ride height and ride name: 60 ride3 Adding rider to line. Amusement Park Info~ Ride 1- Enter minimum ride height and ride name: 75 ridel Ride 2- Enter minimum ride height and ride name: 76 ride2 Sorry can't add rider too short

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

Professional Visual Basic 6 Databases

Authors: Charles Williams

1st Edition

1861002025, 978-1861002020

More Books

Students also viewed these Databases questions