Question 31 Static Field T Initialized Single Statement Initialize 2 Points Question 32 M Q30592654

Question 31 If a static field can’t be initialized in a singlestatement, you can initialize it in a ________________________. 2points Question 32 A ________ method is used to return the valuethat’s stored in a field. 2 points Question 33 If the Point classdoesn’t override the equals() method in the Object class, what willthe following code do? Point pointOne = new Point(3, 4); PointpointTwo = new Point(3, 4);System.out.println(pointOne.equals(pointTwo)); a. Print “true” tothe console b. Cause a compile-time error since the equals() methoddoesn’t exist in the Point class c. Print “false” to the console d.Cause a compile-time error since the equals() method can’t accept aPoint object 2 points Question 34 If two classes share some commonelements, you can define those elements in a/an ____________. 2points Question 35 What class or classes is a method that isdeclared protected available to? a. All classes in all packages b.All classes in the same package c. The current class d. All classesin the same package and to subclasses

0 replies

Leave a Reply

Want to join the discussion?
Feel free to contribute!

Leave a Reply

Your email address will not be published. Required fields are marked *