Counting rectangles

 Published on Friday, 17th December 2004, 06:00 pm; Solved by 24552;
Difficulty rating: 15%

Problem 85

By counting carefully it can be seen that a rectangular grid measuring 3 by 2 contains eighteen rectangles:

Although there exists no rectangular grid that contains exactly two million rectangles, find the area of the grid with the nearest solution.