Children waved at people outside.
Meaning: The young people on the train moved their hands to greet the people who were not on the train.
Choice of Words: Children are young people, and waved means moved their hands to greet someone. At indicates the direction of the waving, and people outside refers to the individuals who were not on the train.
Alternative Expressions
Related Expressions