Sidewalk Running

Leo wants to go to the library with his mom, but he has not complete the running drill of the day yet. Instead of running in the gym, Leo decides to run on the sidewalk. He runs at 4m/s towards the library the moment they leave home. Once he arrives at the library, he turns around and runs at the same speed towards his mom; once he meets his mom, he turns around and runs at the same speed towards the library again; until both Leo and his mom arrive at the library. If the distance between his home and library is 500m, and Leo’s mom is walking at 2m/s, how many meters does Leo run from the moment they leave home until they both arrive at the library?

----------------------

A similar problem was given in Assignment 7 of Charlotte Math Meetup.

Kyle is playing Pokémon Go while walking from home to library with his dad. To maximize the distance Pokémon Go records, Kyle decides to run at 4m/s towards the library the moment they leave home; once he arrives at the library, he turns around and runs at the same speed towards his dad; once he meets his dad, he turns around and runs at the same speed towards the library again; until both Kyle and his dad arrive at the library. If the distance between his home and library is 500m, and Kyle’s dad is walking at 2m/s, how many meters does Kyle run from the moment they leave home until they both arrive at the library?