How to find out if we have to find the GCF or LCM in a question.It's very confusing

Ramon wants to cut a rectangular board into identical square pieces. If the board is 18 inches by 30 inches, what is
the least number of square pieces he can cut without wasting any of the board?

Hi, where’s this question from?

It is from 5lb book under the topic divisibility and primes.

So what would be the approach here? First think about how to solve the problem itself, then think about whether we need GCF or LCM.