A lot of people are assuming the child wandered through the gate by him or herself.. It is also quite possible that the child was already inside, swimming with one or both parents. The parents could have been searching in a bag for a towel, snack, etc, and the child could have just taken off. I have a four year old, I know how fast they can run. I have never been to AoA so I don't know of the lifeguard situation, but with a child that small, in a pool that I'm assuming was super crowded, it may have taken a moment for the lifeguard to spot a problem. A moment is all it takes.
When my daughter was about 3, we were at swim lessons, changing after class. I changed her first and then as I was changing, she started to wander out of our little changing area (no door, just a curtain), into the locker room. I got dressed as fast as I could, calling her back to me the whole time. When I was dressed I searched the whole locker room, and could not find her. Other parents saw me panicking and started looking as well. When we finally found her, she had exited the locker room, went down a hallway, up a flight of stairs and was finally stopped at the exit by another parent. Scariest 5 minutes of my life. I'm sure we have all been there.