A total of 5 + 12 = 17 rows.
The least number of rows she can make is when she puts N marbles in each row, such that N is the greatest common factor between 150 and 360.
To find the greatest common factor between 150 and 360 we can write them as the product of prime numbers.
150 = 15*10 = (3*5)*(2*5)
360 = 36*10 = (6*6)*(2*5) = (2*3*2*3)*(2*5)
greatest common factor between 150 and 360 is the product of these 3 factors:
GCF = 2*3*5 = 30
this means that we need to make rows with 30 marbles each.
150/30 = 5 rows of red marbles
360/30 = 12 rows of pink marbles.
A total of 5 + 12 = 17 rows.