Improve search for last number