Question: public class House { private String myAddress: private int myValue; private int myAge; private boolean hasPool; public House() { myAddress = none; myValue = 0;


public class House { private String myAddress: private int myValue; private int myAge; private boolean hasPool; public House() { myAddress = "none"; myValue = 0; myage = 0; haspool = false; 3 intv int a, public House(String n, boolean p) { my Address myValue = v; myAge = a; hasPool = p; =n: 3 public double getAnswer (double v) { return v * myage / myValue; public int decide(boolean flag) myAge a; hasPool = p; } public double getAnswer (double v) { return v * myAge / my Value; } public int decide(boolean flag) { int ans = myAge; if ( flag ) { ans += myValue; } else { ans += myValue / 2; } return ans; } } Copuriaht p1-2001 Accius Corporation Rights Reserved min261.acellus.com + 13 Given the object declaration: House h = new House("1 Main", 490000, 19, true); Which of the following lines of code do NOT compile? I. double q1 = h.getAnswer(3.1415); II. double q1 = getAnswer 4.5); III. int w = h.decide("true"); A. I. only B. III. only C. II and
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
