Program to calculate fuel consumption