Fixed a small bug in tail recursive solution