How to solve this problem ?

Revision en1, by mike_wasabi, 2019-06-17 18:06:33

John uses a cutter to cut a rectangle of size MxN (N, M integer ≤ 5000) into a number of at least square dimensions of positive integers and have sides parallel to the original rectangular edge. The cutting cutter always cuts in parallel with one of the two sides of the rectangle and divides the rectangle into two parts. Calculate the number of squares created.

For example, with M = 5 and N = 6, the minimum number of squares that can be generated is 5.

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en1 English mike_wasabi 2019-06-17 18:06:33 486 Initial revision (published)