Created a distance calculator class