Originally Posted by

**bdario1** here are the documents for the method we need to create.

** /****

* This method finds and returns the smallest rectangle in the

* array. The smallest rectangle is defined as the one

* with the smallest area. If two rectangles have the same

* smallest area, the one that occurs last in the array

* is returned.

* <p>

*

* This method requires that the rectangles array

* must not contain null.

* <p>

*

* <p><b>You will write this method as part of programming assignment #9.</b>

*

* @param rectangles An array of rectangle objects

* @return The smallest rectangle in the array

* @throws NullPointerException If rectangles is null or rectangles contains null

*/

and i need to test it with For findSmallest, the input array{new Rectangle(0, 0, 3, 8), new Rectangle(1, 1, 6, 7), new Rectangle(2, 2, 6, 4)} should return the last rectangle object - Rectangle(2, 2, 6, 4)