If you have 24 party favors and 42 treats, what is the greatest amount of party bags you can make that would have and equal number of favors and treats?

I think that the answer is that you can make 12 party bags, because then there would be 2 party favors in each bag and 3.5 treats in each bag. is this correct? if not, please explain why not and the correct way to solve it.

I don't think that partial treats or favours would be acceptable.

If that were the case, then you could have any number of bags with partial treats and favours.
e.g. suppose we want 8 bags, they would each contain 3 favours and 5 1/4 treats

What you want the lowest common factor , which would be 6

So you can have a maximum of 6 bags, each containing 24/6 or 8 favours and 42/6 or 7 treats per bag.