Improved toString() so that distances are formatted properly.