Corrected code so all children's messages are printed.