Completed distance.py calculating program