There are 48 cookies and 60 pieces of candy. The teacher uses all of the candy and cookies to fill bags for the students. He puts the same ratio of cookies to candy in each bag. What is the largest number of bags he could have made?

He has 108 cookies.

48/108 = 4/9
60/108 = 5/9
so try 4 cookie/5 candy
how many bags of 9 can he make?
108/9 = 12 bags

To find the largest number of bags the teacher could have made, we need to determine the greatest common divisor (GCD) of the number of cookies and candy pieces.

First, let's find the GCD of 48 cookies and 60 pieces of candy.

To do this, we can use the Euclidean algorithm:
1. Divide the larger number (60) by the smaller number (48).
- 60 ÷ 48 = 1 remainder 12
2. Divide the remainder (12) by the previous divisor (48).
- 48 ÷ 12 = 4 remainder 0

Since the remainder is now 0, we can stop the algorithm. The GCD is the last non-zero remainder, which is 12.

The GCD of 48 and 60 is 12.

The teacher can make the largest number of bags equal to the GCD, which is 12.