Teaser 3334: All square

From The Sunday Times, 16th August 2026 [link] [link]

The diagram shows a grid of three rows and five columns of identical small squares. Within that grid one can also spot some larger squares giving a grand total of 26 squares (namely fifteen 1×1 squares, eight 2×2 and three 3×3).

Now I have drawn a larger such grid (with fewer than 50 columns and even fewer rows). Within this new grid there is a grand total of exactly 10,000 squares.

How many rows and how many columns does this new grid have?

[teaser3334]