There is a mitzvah to be from the asara rishonim, and this mitzvah applies to all three tefillos. If one came to shul for Maariv (first person there) but he is a katan, and at tzeis he became a gadol, does he fulfill the mitzvah – when he came in, he didn’t count for the minyan?
If one came in (first person there) and fell asleep, and then woke up in time for davening, does he get the mitzvah (he didn’t count for the minyan when he was sleeping)?
There are two reasons why asara rishonim is so special that they get “sechar k’neged kolam”, is because the person helped cause the shechina to come, and because when the person got up early to be in shul it before anyone else shows that davening is important to him. (See Asufas Ma’amarim (Korach) pg. 436, that the Rambam holds of the latter reason.) When the child is in shul early, even if he couldn’t be part of the minyan yet, he surely has the other reason, that he showed that davening is important to him.
Regarding the person that came first and fell asleep, he would also have at least the second reason. If he has the first reason might depend on the controversy if he can be included in the minyan.
Kesiva V’chasima Tova