Step-by-step explanation:
x=number of miles traveled
y=number of friends in the cab
z=cost of each friend
If carlos and his friends travel the same distance, x, then the total cost of the cab is x*1.50.
if there are y friends in the cab, then we must divide the total of the cab by the number of people inside that traveled to obtain the cost of each one.. it is z = x*150/(y+1)
notice that i used y + 1, that is because there are y friends and carlos, so the amount of money is divided by y + 1.