Answer:
print("TAXI FARE CALCULATOR\n")
beginning = float(input("Enter beginning odometer reading => "))
ending = float(input("Enter ending odometer reading => "))
distance = ending - beginning
fare = 1.50 * distance
print("You traveled a distance of %.1f" % distance + " miles. At $1.50 per mile, your fare is $ %.2f" % fare)
Explanation:
*The code is in Python.
Print the title
Ask the user to enter beginning and ending of the odometer reading. Calculate the distance by subtracting these values
Calculate the fare, multiply the distance by 1.50
Print the distance and fare in required format