Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

53. public clase length public Rectangle(double I, double w length- 1 width- pub

ID: 3726611 • Letter: 5

Question

53. public clase length public Rectangle(double I, double w length- 1 width- public void set(double I, double w length-1; width-w public void printO System.out-printin(length+width), public double area return length width; public double perimeterO return 2 length +2 width; Suppose that you have the following declaration. Rectangle bigRect- new Rectangle(10,4); Which of the following set of statements are valid in Java? bigRect.area0 bigRect.perimeter0 bigRect.print0 bigRect.area bigRect.area0: bigRect.perimeter bigRect.perimeterO bigRect.print0; c. Both () and (i) d. None of these a. Only () b. Only (il)

Explanation / Answer

53.a) only (i)(Private member of class can not be access outside the class.So ii is not valid.)

55.c)Both (i) and (ii)(All function are public so we can access it by instance.)

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote