IDNLearn.com helps you find the answers you need quickly and efficiently. Discover thorough and trustworthy answers from our community of knowledgeable professionals, tailored to meet your specific needs.

Question 1 The Movie class includes a toString method. Suppose another class is using the Movie class and has declared m as a Movie and initialized m. Which TWO of the following would use the toString method correctly to print out information about the movie m? 1 point 1 System.out.println(m); 1 System.out.println(toString()); 1 System.out.println(m.toString); 1

Sagot :

The two print statement which would use the toString method correctly to print out information about the movie m are:

  1. System.out.println(toString()); 1.
  2. System.out.println(m.toString()); 1.

What is a method?

In Computer programming, a method can be defined as a block of executable code (sets of instruction) that are written and used by programmers to break down a given problem into small but manageable fragments (pieces).

This ultimately implies that, methods are typically written and used by programmers to break down any complex problem into simple and manageable fragments (pieces) such as in modern programming languages, which comprises several predefined methods.

In conclusion, the "System.out.println(toString());1" and "System.out.println(m.toString()); 1" calls the toString() function which then returns the string representation of the object movie.

Read more on print methods here: https://brainly.com/question/19594241

#SPJ1