1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Olenka [21]
3 years ago
13

Write a program that uses a structure named MovieData to store the following information about a movie: Title Director Year Rele

ased Running Time (in minutes) The program should create two MovieData variables, store values in their members, and pass each one, in turn, to a function that displays the information about the movie in a clearly formatted manner.
Computers and Technology
1 answer:
Len [333]3 years ago
7 0

Answer:

#include <iostream>

#include <string>

using namespace std;

struct MovieData {

string Title;

string Director;

unsigned short YearReleased;

unsigned short RunningTime;

};

void displayMovieInfo(MovieData &md) {

cout << "The Title is: " << md.Title << endl

<< "The Director is: " << md.Director << endl

<< "The Year of Release: " << md.YearReleased << endl

<< "The Running Time: " << md.RunningTime << " minutes" << endl;

}

int main() {

MovieData firtMovie, secondMovie;

firtMovie.Title = "Starship Troopers";

firtMovie.Director = "Paul Verhoeven";

firtMovie.YearReleased = 1997;

firtMovie.RunningTime = 129;

secondMovie.Title = "Alien vs. Predator";

secondMovie.Director = "Paul W. S. Anderson";

secondMovie.YearReleased = 2004;

secondMovie.RunningTime = 108;

cout << endl;

displayMovieInfo(movFirst);

cout << endl;

displayMovieInfo(movSecond);

cout << endl;

system("pause");

return 0;

}

Explanation:

In this program a structure that contains the class feilds for four attributes of a movie (Title, Director, Year Released and Running Time) we declared this with their appropriate data types.

Next we create a function (Method) called displayMovieInfo that will print a clearly formatted output of the movies when called and given appropriate parameters.

Finally we create the main function where we create two movie objects and make function calls to the displayMovieInfo and pass the two movies to the displayMovieInfo function to display their information

You might be interested in
In addition to good design sense, what else do web designers need to be proficient in?
ELEN [110]

In addition to good design sense, web designers need to be proficient in front-end coding languages.

A web designer refers to an individual who is saddled with the responsibility of writing executable codes (instructions) for the design and development of a website, especially by using a hypertext markup language (HTML).

Generally, it is expected that all web designers a good design sense in website development. Additionally, web designers need to be proficient in front-end coding languages, so as to ensure the graphical display and user-interface (UI/UX) are attractive and properly rendered.

Some examples of front-end coding languages include:

  • CSS
  • HTML
  • Javascript
  • React
  • JQuerry
  • Vue

Read more on web design here: brainly.com/question/8391970

7 0
2 years ago
When troubleshooting firewalls, which of the following is not something you should do after you attempt a fix?
mart [117]

Answer:

a. make multiple fixes.

Explanation:

When we are troubleshooting firewalls we should not make multiple fixes after attempting a fix because it will not be beneficial for the security purpose.

We can repeat the failure after attempting the fix because we can fix it but a person with right mind won't be doing that.

We can test after each attempt that it is working properly.

We can also  reverse or undo the solution failures after making a fix.

5 0
3 years ago
What is a variable?
aleksandr82 [10.1K]
Answer. D: a value that looks loads when the program runs.


Explanation:

In programming, a variable is a value that can change, depending on conditions or on information passed to the program. Typically, a program consists of instruction s that tell the computer what to do and data that the program uses when it is running.
5 0
3 years ago
Ava calls tech support because she is unable to send information that a customer has requested. The tech support person tells he
Blizzard [7]

Answer:

Outlook as it is a common email aplication which may experience some issues

Explanation:

7 0
3 years ago
Samuel was hired to create a program that asks the user questions and, based on the answers, recommend a book to read. What kind
quester [9]

Answer:

I think the answer is C

Explanation:

Selection

3 0
3 years ago
Other questions:
  • The fractional_part function divides the numerator by the denominator, and returns just the fractional part (a number between 0
    8·1 answer
  • What are the key ideas in dealing with a superior?
    9·1 answer
  • Write a Python 3 script in PyCharm that will simulate the game of "Rock, Paper, Scissors": Display a header and the simple rules
    8·1 answer
  • Similarities between inline css and internal css​
    6·1 answer
  • Write a program that first reads in the name of an input file and then reads the input file using the file.readlines() method. T
    11·1 answer
  • Use the drop-down menus to answer the questions.
    6·1 answer
  • Taylor and Rory are hosting a party. They sent out invitations, and each one collected responses into dictionaries, with names o
    9·1 answer
  • Bryan's company is new and has limited funds to work with. He has been tasked with finding a telecommunications technology that
    7·1 answer
  • Name various input and output devices used with computers.
    7·1 answer
  • The function that overloads the ____ operator for a class must be declared as a member of the class.
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!