takes input of locations from user and calculates distance between them using googlemaps
from googlemaps import Client as GoogleMaps from math import sin, cos, sqrt, atan2, radians gmaps = GoogleMaps("AIzaSyD9Y-kLgDZvhjtKl_--5o5P5Cwq0K3qrD8") def get_distance(origin, destination): my_dist = gmaps.distance_matrix(origin, destination)['rows'][0]['elements'][0] return my_dist['distance']['value'] def get_coordinates(origin, destination): my_dist = gmaps.distance_matrix(origin, destination)['rows'][0]['elements'][0] return my_dist['duration']['value'] def get_distance_from_user(): origin = input("Enter the Origin: ") destination = input("Enter the Destination: ") return get_distance(origin, destination) def get_coordinates_from_user(): origin = input("Enter the Origin: