#include #include "fuel.h" float avarage_fuel_per_mile (int miles_one_year_ago, int miles_today, int liters) { int miles = miles_today - miles_one_year_ago; float liters_per_mile; if (miles == 0 && liters == 0) { liters_per_mile = 0; } else { liters_per_mile = liters/(float)miles; } return liters_per_mile; }