Hello Madeleine,
Since the ratio of children to adults at the festival was 3:5, you can add the two numbers and that will give you the total number of "cake slices" so 3+5 = 8.
The entire "cake" represents the total amount of people present at the festival. That would be 4000.
3 slices out of 8 represent the total number of children so you would multiply the total number of people by 3 and DIVIDE by 8: 4000*3/8 = 1500 children
5 slices out of 8 represent the total number of adults so you would multiply the total number of people by 5 and DIVIDE by 8: 4000*5/8 = 2500 adults
1500 + 2500 = 4000, so it all adds up perfectly.