--- id: 5900f3c11000cf542c50fed4 challengeType: 5 title: 'Problem 85: Counting rectangles' forumTopicId: 302199 --- ## Description
By counting carefully it can be seen that a rectangular grid measuring 3 by 2 contains eighteen rectangles: a diagram of the different rectangles found within a 3 by 2 rectangular grid Although there exists no rectangular grid that contains exactly two million rectangles, find the area of the grid with the nearest solution.
## Instructions
## Tests
```yml tests: - text: countingRectangles() should return a number. testString: assert(typeof countingRectangles() === 'number'); - text: countingRectangles() should return 2772. testString: assert.strictEqual(countingRectangles(), 2772); ```
## Challenge Seed
```js function countingRectangles() { return true; } countingRectangles(); ```
## Solution
```js // solution required ```