the first player takes two candies, the second should take one. then after every round (in which both players move once), there will be exactly 3 fewer candies in the pile than in the previous round, so after the sixth round, the second player will win.
the game does not necessarily have to begin with exactly 18 candies; it can be any number divisible by 3. to make sure your child finds the right strategy, it may be worth starting with 6 candies and letting him go second. then you can begin by taking two candies. if your child takes two candies as well, you have won: let him try again. 