How do you do this?don’t understand

If 10 candies cost like 2 chocolate bars, then 5 candies cost like 1 chocolate bar.
So, 5 candies and 3 chocolate bars cost as much as 4 chocolate bars.
If 4 chocolate bars cost 8 dollars, then 1 chocolate bar costs 2 dollars.