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
MakcuM [25]
4 years ago
13

rite a function to prompt the user to enter the information for one movie (title, release date, mpaa rating and number of stars)

. This function should then return the movie information back to main. You should call this function twice, once for each of the MovieInfo variables in main.
Computers and Technology
1 answer:
vesna_86 [32]4 years ago
7 0

Answer:

import java.util.*;

public class Movie {

   

   public static void main (String [] args) {

       

       System.out.println(movieInfo());

       

   }

   public static String movieInfo() {

       Scanner input = new Scanner(System.in);

       Scanner input2 = new Scanner(System.in);

       

       System.out.print("Enter the title: ");

       String title = input.nextLine();

       System.out.print("Enter the release date: ");

       String releaseDate = input.nextLine();

       System.out.print("Enter the mpaa rating: ");

       double mpaaRating = input2.nextDouble();

       System.out.print("Enter the number of stars: ");

       double numberOfStars = input2.nextDouble();

       

       return "Title: "+title+ "\nRelease Date: "+releaseDate+ "\nMPAA Rating: "+ mpaaRating+ "\nNumber of Stars: "+numberOfStars;

   }

}

Explanation

- Create a function called <em>movieInfo()</em> that returns a string, information about a movie

- Ask the user to enter the title, release date, mpaa rating and number of stars of the movie.

- Return these values at the end of the function

- Inside the main, call the function to see the information about the movie

You might be interested in
It is always better to run over and give more information when you are giving a presentation versus quitting on time. true false
GaryK [48]
True , to make your audience interested you should always give more information on the subject but don't bore them so that they wish for you to quit on time
8 0
3 years ago
Read 2 more answers
The people on this platform are unbelievably nice. its almost rare to see this type of kindness online these days. Just wanted t
baherus [9]

Answer:

thanks

Explanation:

5 0
3 years ago
Do you like Houseparty?
steposvetlana [31]
Yes it’s really fun
3 0
4 years ago
I need help pleaseeeeeee!
sertanlavr [38]

Answer:

located on the x axis

the x axis is horizontal and y axis vertical

8 0
3 years ago
Read 2 more answers
A _____ provides a file-system interface which allows clients to create and modify files.
stiv31 [10]
The correct answer is a file-server system. Hope this helps!
3 0
4 years ago
Other questions:
  • Which process refers to starting up a computer?
    15·2 answers
  • Which option enables you to keep the last grammatical change
    15·2 answers
  • A user would like to format an arrow that has been inserted into a chart. What is the most efficient method for completing this
    9·1 answer
  • What is the purpose of system calls, and how do system calls relate to the OS and to the concept of dual-mode (kernel-mode and u
    14·1 answer
  • Edhesive coding practice 3.4​
    12·1 answer
  • How to interchange first half of the array with second half of array in python?
    9·1 answer
  • What software could i use to create music like Aphex Twin?
    6·1 answer
  • PYTHON CODING QUESTION
    10·1 answer
  • a) In an office, it is required to take hundreds of copies of the same type written document. Which traditional method of docume
    11·1 answer
  • What is word processing program,Give 3 types of word processing program​
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!