2.
Consider the following class definition.
public class WhatsIt {
private int length;
private int width;
public int getArea () {
// implementation not shown
}
private int getPerimeter () {
// implementation not shown
}
}
A child class Thingy that extends WhatsIt would have access to:
getArea()
getPerimeter()
width, length, getPerimeter()
width, length, getArea()
all of the above
Questions 3-5 pertain to the following class, Point:
public class Point {
private double x;
private double y;
public Point() {
this (0, 0);
}
public Point(double a, double b) {
/* missing code */
}
// ... other methods not shown