Assume the variable costOfBusRental has been declared as an int and assigned the amount that it costs to rent a bus. Also assume the variable maxBusRiders has been declared as an int and assigned the maximum number of riders on a bus. Write an expression that computes the cost per rider, assuming the bus is full.

Answer :

It’s a total price divided to a number of riders involved. So costPerRider = costOfBusRental/maxBusRiders

Other Questions