0
/ 1.0
For this question assume the following implementations of Computer, Tablet, and Notebook
public class Computer { private String...
For this question assume the following implementations of Computer, Tablet, and Notebook
public class Computer {
private String manufacturer;
private String processor;
private int ramSize;
private int diskSize;
private double processorSpeed;
public Computer(String man, String pro, int raSize, int diSize, double proSpeed) {
manufacturer = man;
processor = pro;
ramSize = raSize;
diskSize = diSize;
processorSpeed = proSpeed;
}
public String getManufacturer() {
return manufacturer;
}
public String getProcessor() {
return processor;
}
public int getRamSize() {
return ramSize;
}
public int getDiskSize() {
return diskSize;
}
public double getProcessorSpeed() {
return processorSpeed;
}
}
Write an equals method for Computer that will take in an Object obj and return true if the two classes are equal. Equals will return true if:
Or if both of the following are true:
Your feedback will appear here when you check your answer.