Created an equals method for the rectangle object.
Adding proper hash code method to Rectangle so that the equals method functions appropriately.