Solution:
The first car can travel 75 miles on 5 gallons of gas.
So per mile gas consumed by car gallon
The second car can travel 240 miles on 20 gallons of gas.
So per mile gas consumed by car gallon
It mean Sam should rent the First car.
Sam is renting one of two cars to go on a 300-mile trip.
So total number of gallons of gas required
Total cost of 20 gallons of gas dollar