Given two numbers M and N, which represents the length and breadth of a paper, the task is to cut the paper into squares of any size and find the minimum number of squares that can be cut from the paper.
- Time : O(nm)
- Space : O(nm)
c++
1 | class Solution { |