How can I make it so the toEq() method compare if the method boolean equals(Object b) results in false or true and then assign a string? Thanks
public boolean equals(Object b) { if(!(b instanceof Rectangle3)) return false; Rectangle3 t = (Rectangle3)b; return t.getLength() == getLength() && t.getWidth() == getWidth() && height == height; } public String toEq() { if(equals() == false) { return "same"; } else { return "not the"; } }