separate out key distance