Loneliness means being sad, not having anyone to be with. As he was cycling down the road, he recalled what the roller skater said about skating fast enough to leave your loneliness behind. He wondered if this could also be done by cycling, he found out immediately that this method works. As he pedaled on, he realized he was happy.
I hope this helps :)