Translation:Children like candies and treats.
と indicates that your list is exhaustive, i.e. you are mentioning everything.
や indicates that your list is not (necessarily) exhaustive, so it is more a "things like... and like...". Since children in general like more than just candies and treats, と would be a bit weird to use here.
In one of the previous questions お菓子 was translated as "snack", which I found odd, because it's normally a candy, or a treat. Here it's a treat but not a snack. At a very minimum at least keep a consistent list of translations for the questions, especially in a single section.
On the flip side though...
The kanji 飴 (あめ, "candy") isn't used so much. It's not in the list of the 2,136 jōyō kanji learnt in Japanese schools, nor is it even in the list of the 863 additional jinmeiyō kanji that can be used in names. 飴 isn't one of those 2,999 kanji.
Whereas 雨 (あめ, "rain") is one of the 80 kanji taught in the very first year of elementary school.
雨 is an N5 JLPT level kanji, which is the level this course is based around. Even for people studing for N1 (the highest JLPT level), 飴 usually still isn't listed as a kanji that should be learned.
So, I think あめ not being written in kanji is a very strong indicator that it's not going to mean "rain" 雨. And you can see why this course might not have gotten around to teaching the kanji 飴 or any of its rarer variants, since we haven't quite reached the point of having already learned 2,999 kanji yet. ^^