<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def all_child_sprites(self):
 """returns all child and grandchild sprites in a flat list"""

        for sprite in self.sprites:
            for child_sprite in sprite.all_child_sprites():
                yield child_sprite
            yield sprite