added lenght to path and distance