PROGRAM TRIP(INPUT,OUTPUT);
VAR
DISTANCE,SPEED,TIME,GALCOST,
MPG,GALUSED,TOTALCOST:REAL;
BEGIN
WRITELN('* COMPUTE TRIP TIME AND COST *');
WRITELN('DISTANCE?');
READ(DISTANCE);
WRITELN('AVERAGE SPEED?');
READ(SPEED);
WRITELN('MILES PER GALLON');
READ(MPG);
WRITELN('COST PER GALLON');
READ(GALCOST);
WRITELN;
WRITELN('DISTANCE = ',DISTANCE:8:2,' MILES');
WRITELN('AVERAGE SPEED = ',SPEED:8:2,' MILES');
TIME:=DISTANCE/SPEED;
WRITELN(' TIME OF TRIP = ',TIME:8:2,' HOURS');
WRITELN;
WRITELN('MILEAGE RATE = ',MPG:8:2,' MILES/GAL');
WRITELN('$ PER GALLON = ',GALCOST:8:2,' DOLLARS');
GALUSED:=DISTANCE/MPG;
TOTALCOST:=GALUSED*GALCOST;
WRITELN(' ESTIMATED TRIP EXPENSE = ',TOTALCOST:8:2,
' DOLLARS');
END.
Print a copy of the file on the system printer. Label it with