Here are the contents for a movie: Lab 27 Home Alone Jeff Nunn 1990 Here are the contents for a movie: Rocky Al Davis 1984 NCEPTS: • More practice with the setter and getter functiofns. Enter the year of the movie to search for 1984 Found movie Rocky sk list: cscill1/lab27$ ./lab27 Here are the contents for a movie: Start by running the code listed below Create a searchMovie function within the Library class that searches for a movie given a year as a parameter value. Refer to the expected output listing below. Submit your lab27.cpp file on Home Alone Jeff Nunn 1990 Here are the contents for a movie: Rocky Al Davis and get a successful message. 1984 AMPLE OUTPUT (output shown in RED should be displayed from within the main function) Enter the year of the movie to search for 1990 1/cscill1/lab27$ ./lab27 ere are the contents for a movie: ome Alone Found movie Home Alone /cscill1/lab27$ eff Nunn 990

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question
100%

Please answer.. It's urgent. Don't reject

Read carefully and write code

2 / 2
100%
SUing geUDIrector (
return director;
int getYear () (
return year;
include <iostream>
include<vector>
using namespace std:
class Library
class Movie
private:
vector<Movie> movievector;
public:
private:
string title;
string director;
int year;
void setMovie (Movie ml)
movievector.push back (ml);
public:
void setMovie (string sl, string d1, int yl)
void displayMovies ()
title - sl;
director d1;
year - yl;
for (int i = 0; i < movievector. size (); i++)
cout << "Here are the contents for a movie:" << endl;
cout << movievector[i].getTitle () << endl;
cout << movievector[i].getDirector 0 « endl;
cout << movievector[i]. getYear () << endl;
string getTitle ()
return title;
string getDirector ()
return director;
int main ()
int getYear () (
return year:
Library mylibrary;
Movie objl;
objl.setMovie ("Home Alone", "Jeff Nunn", 1990) :
Movie obj2;
obj2.setMovie ("Rocky", "Al Davis", 1984):
class Library
private:
vector<Movie> movieVector;
public:
mylibrary.setMovie (objl);
mylibrary.setMovie (obj2);
mylibrary.displayMovies ();
void setMovie (Movie ml)
movievector.push_back (ml);
return 0;
void displayMovies ()
for (int i- 0; 1< movievector.size (); i++)
cout << "Here are the contents for a movie:" << endl;
cout << movievector[i]. getTitle () « endl;
cout << movieVector [i).getDirector () << endl;
cout <e moievectorlil.getYear 0 « andl.
Transcribed Image Text:2 / 2 100% SUing geUDIrector ( return director; int getYear () ( return year; include <iostream> include<vector> using namespace std: class Library class Movie private: vector<Movie> movievector; public: private: string title; string director; int year; void setMovie (Movie ml) movievector.push back (ml); public: void setMovie (string sl, string d1, int yl) void displayMovies () title - sl; director d1; year - yl; for (int i = 0; i < movievector. size (); i++) cout << "Here are the contents for a movie:" << endl; cout << movievector[i].getTitle () << endl; cout << movievector[i].getDirector 0 « endl; cout << movievector[i]. getYear () << endl; string getTitle () return title; string getDirector () return director; int main () int getYear () ( return year: Library mylibrary; Movie objl; objl.setMovie ("Home Alone", "Jeff Nunn", 1990) : Movie obj2; obj2.setMovie ("Rocky", "Al Davis", 1984): class Library private: vector<Movie> movieVector; public: mylibrary.setMovie (objl); mylibrary.setMovie (obj2); mylibrary.displayMovies (); void setMovie (Movie ml) movievector.push_back (ml); return 0; void displayMovies () for (int i- 0; 1< movievector.size (); i++) cout << "Here are the contents for a movie:" << endl; cout << movievector[i]. getTitle () « endl; cout << movieVector [i).getDirector () << endl; cout <e moievectorlil.getYear 0 « andl.
Lab 27
Here are the contents for a movie:
Home Alone
Jeff Nunn
1990
Here are the contents for a movie:
Rocky
Al Davis
1984
CONCEPTS:
• More practice with the setter and getter functions.
Enter the year of the movie to search for
1984
Found movie Rocky
Task list:
cscil11/lab27$ ./lab27
Here are the contents for a movie:
Home Alone
1. Start by running the code listed below
2. Create a searchMovie function within the Library class that searches for a movie given a year as a parameter
Jeff Nunn
1990
value,
3. Refer to the expected output listing below.
4. Submit your lab27.cpp file on
Here are the contents for a movie:
Rocky
Al Davis
1984
and get a successful message.
SAMPLE OUTPUT (output shown in RED should be displayed from within the main function)
Enter the year of the movie to search for
/cscill1/lab27$./lab27
1990
Found movie Home Alone
Here are the contents for a movie:
Home Alone
/cscill1/1ab27$
Jeff Nunn
1990
Here are the contents fora movie:
Rocky
Al Davis
1984
Enter the year of the movie to search for
1984
Found movie Rocky
#include <iostream>
#include<vector>
using namespace std;
/cscill1/1ab27$./lab27
Here are the contents for a moOvie:
Transcribed Image Text:Lab 27 Here are the contents for a movie: Home Alone Jeff Nunn 1990 Here are the contents for a movie: Rocky Al Davis 1984 CONCEPTS: • More practice with the setter and getter functions. Enter the year of the movie to search for 1984 Found movie Rocky Task list: cscil11/lab27$ ./lab27 Here are the contents for a movie: Home Alone 1. Start by running the code listed below 2. Create a searchMovie function within the Library class that searches for a movie given a year as a parameter Jeff Nunn 1990 value, 3. Refer to the expected output listing below. 4. Submit your lab27.cpp file on Here are the contents for a movie: Rocky Al Davis 1984 and get a successful message. SAMPLE OUTPUT (output shown in RED should be displayed from within the main function) Enter the year of the movie to search for /cscill1/lab27$./lab27 1990 Found movie Home Alone Here are the contents for a movie: Home Alone /cscill1/1ab27$ Jeff Nunn 1990 Here are the contents fora movie: Rocky Al Davis 1984 Enter the year of the movie to search for 1984 Found movie Rocky #include <iostream> #include<vector> using namespace std; /cscill1/1ab27$./lab27 Here are the contents for a moOvie:
Expert Solution
steps

Step by step

Solved in 3 steps with 4 images

Blurred answer
Knowledge Booster
JQuery and Javascript
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education