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
bija089 [108]
2 years ago
10

Write, compile, and test the MovieQuoteInfo class so that it displays your favorite movie quote, the movie it comes from, the ch

aracter who said it, and the year of the movie: I GOT IT DONT WATCH AD.
class MovieQuoteInfo {
public static void main(String[] args) {
System.out.println("Rosebud,");
System.out.println("said by Charles Foster Kane");
System.out.println("in the movie Citizen Kane");
System.out.println("in 1941.");
}
}
Computers and Technology
1 answer:
Irina18 [472]2 years ago
7 0

Using the knowledge of computational language in JAVA it is possible to write a code that removes your favorite phrase from the movie. It consists of two classes in which one is driver code to test the MovieQuoteInfo class.

<h3>Writing code in JAVA:</h3>

<em>public class MovieQuoteInfo { //definition of MovieQuoteInfo class </em>

<em> //All the instance variables marked as private </em>

<em> private String quote;</em>

<em> private String saidBy;</em>

<em> private String movieName;</em>

<em> private int year;</em>

<em> public MovieQuoteInfo(String quote, String saidBy, String movieName, int year) { //parameterized constructor </em>

<em>  super();</em>

<em>  this.quote = quote;</em>

<em>  this.saidBy = saidBy;</em>

<em>  this.movieName = movieName;</em>

<em>  this.year = year;</em>

<em> }</em>

<em> //getters and setters </em>

<em> public String getQuote() {</em>

<em>  return quote;</em>

<em> }</em>

<em> public void setQuote(String quote) {</em>

<em>  this.quote = quote;</em>

<em> }</em>

<em> public String getSaidBy() {</em>

<em>  return saidBy;</em>

<em> }</em>

<em> public void setSaidBy(String saidBy) {</em>

<em>  this.saidBy = saidBy;</em>

<em> }</em>

<em> public String getMovieName() {</em>

<em>  return movieName;</em>

<em> }</em>

<em> public void setMovieName(String movieName) {</em>

<em>  this.movieName = movieName;</em>

<em> }</em>

<em> public int getYear() {</em>

<em>  return year;</em>

<em> }</em>

<em> public void setYear(int year) {</em>

<em>  this.year = year;</em>

<em> }</em>

<em> //overriden toString() to print the formatted data</em>

<em> public String toString() {</em>

<em>  String s = quote+",\n";</em>

<em>  s+="said by "+this.saidBy+"\n";</em>

<em>  s+="in the movie "+this.movieName+"\n";</em>

<em>  s+="in "+this.year+".";</em>

<em>  return s;</em>

<em> }</em>

<em>}</em>

<em>Driver.java</em>

<em>public class Driver { //driver code to test the MovieQuoteInfo class</em>

<em> public static void main(String[] args) {</em>

<em>  MovieQuoteInfo quote1 = new MovieQuoteInfo("Rosebud", "Charles Foster Kane", "Citizen Kane", 1941);//Create an object of MovieQuoteInfo class</em>

<em>  System.out.println(quote1); //print its details </em>

<em> }</em>

<em>}</em>

See more about JAVA at brainly.com/question/12975450

#SPJ1

You might be interested in
Hank is the network administrator responsible for managing the web server cluster for an e-commerce company. He’s worried about
statuscvo [17]

Answer: ....

If one load balancer fails, the secondary picks up the failure and becomes active. They have a heartbeat link between them that monitors status. If all load balancers fail (or are accidentally misconfigured), servers down-stream are knocked offline until the problem is resolved, or you manually route around them.

Explanation:

Load balancing is a technique of distributing your requests over a network when your server is maxing out the CPU or disk or database IO rate. The objective of load balancing is optimizing resource use and minimizing response time, thereby avoiding overburden of any one of the resources.

The goal of failover is the ability to continue the work of a particular network component or the whole server, by another, should the first one fail. Failover allows you to perform maintenance of individual servers or nodes, without any interruption of your services.

It is important to note that load balancing and failover systems may not be the same, but they go hand in hand in helping you achieve high availability.

3 0
2 years ago
To exclude members of a group from the basic permissions for a folder, which type of permission would you assign? Deny Allow Mod
oksano4ka [1.4K]

Answer:

Deny

Explanation:

Under the New Technology System, the Deny permission is applied when the administrator wants to overrule the permission given to members of a group. The Allow and Deny options help in regulating access to the components of the system. Only authorized groups are granted access to the files.

Most times, the Deny permission is considered before the Allow permission. If the user is denied access to some files and granted access to some, the deny permission is most times considered first.

4 0
3 years ago
How is peace circulated?​
Agata [3.3K]

Answer:

Peace is when people are able to resolve their conflicts without violence and can work together to improve the quality of their lives. 

6 0
3 years ago
Read 2 more answers
Todd insisted on having an image to go with every slide. Is this good or bad?
valentina_108 [34]

Answer:

Yes, Its a good idea but depends upon type of image. Like adding a logo to all the slides at top left corner is not just good but a must for all as well, when we are preparing official documents. However, other images when decided to be repeated must convey the correct intent in each page. If this is not the case, you need to avoid it. Intent is the most important aspect certainly. For rest see explanation.

Explanation:

Yes, and as mentioned above adding logo and other images meaningfully, and with correct intent is a good idea.

However, images must not be blurred, tiny or stretched. Also proper cropping is a must. The border should be solid as well. And when selecting a lot of images, the images must convey the correct meaning together. Moreover, the aspect ratio after stretching must be same as the original. You can do this in PowerPoint by going to format > crop > fill.

Ensure that watermarks are not revealed. Buy them rather than copy from somewhere for better outcome. And never amputate your readers with a headache creating backgrounds. You will loose readers then. The clip arts must be used in right number, and not a lot of them certainly.

Ensure both text and images are in correct ratios. Avoid using more than 2 images per slide.

5 0
2 years ago
Read 2 more answers
In the mouse properties window you can
Nikitich [7]
When u are in the mouse properties window you can change the speed in which your pointer moves, change the speed of your double click on the mouse, change the look of the pointer make the pointer automatically move to default button in a dialog box have the pointer hide while you are typing. and change the number of lines that the scroll wheel will move when using it. there's actually a lot of optoons available in the mouse properties window. HOPE I WAS HELPFULL
4 0
3 years ago
Other questions:
  • Which of the following is a Microsoft solution that runs on a Microsoft Terminal Services server but appears, to end users, as i
    10·1 answer
  • You have just replaced the NIC on a server, making no other changes. It can communicate with all the computers on its network bu
    14·1 answer
  • The mac group does not replace the primary functions of eocs or other dispatch organizations. True or False
    8·1 answer
  • Explain with the help of an example that family background affects the entrepreneurial behaviour of people
    12·1 answer
  • Which screen should be open to customize or personalize a desktop background?
    15·2 answers
  • During a test, it is generally best to: A. answer all questions in order B answer the essay questions first C. answer the least
    7·2 answers
  • Adam is writing a program that: 1) has the user guess a number, and 2) tells the user how many guesses it took to get the correc
    9·2 answers
  • The auxiliary device used to store large volume of data and program for future is called​
    10·1 answer
  • Vegetable farming is a good source of income explain this statement<br>​
    5·1 answer
  • Upload your completed project including the following:
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!