Question: *USING C++ PROGRAMMING* TUTORIAL CHAPTER 4(STRUCT) Most of people especially teenagers like to watch movies in cinema. There are variety of movies available currently such

 *USING C++ PROGRAMMING* TUTORIAL CHAPTER 4(STRUCT) Most of people especially teenagers

*USING C++ PROGRAMMING*

TUTORIAL CHAPTER 4(STRUCT) Most of people especially teenagers like to watch movies in cinema. There are variety of movies available currently such Avengers: The Endgame, Detective Pikachu, BTS: Burn the Stage, Paskal and etc. Each movie has its characteristics, which are title, genre, duration (in seconds) and classification (such as U,P13 and 18). 1. Write a struct definition for the movie based on the characteristics given. (1 Mark) 2. Create an array named MovieList to store 5 movies in main (1 Mark) 3. Write the function definition for each of the following : (3 Marks) a. Function inputData( ): This function receives two parameters; an array of movies and the size of the array. It then reads data from the user and stores them into the array. b. Function longestDuration( ): this function receives two parameters; an array of movie and the size of the array. It then determines and then display all information of the movie that has the longest duration. (5 Marks) c. Function Count(): This function receives two parameters; an array of movie and the size of the array. It then count how many movies that are classified as "18" then return the value to the main. (3 Marks) d. Write the main function : (2 Marks) i. Call inputData() fucntion to get the value form the user. ii. Call longestDuration( ) function

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!