Lyft’s mobile-phone application facilitates peer-to-peer ridesharing by connecting passengers who need a ride to drivers who have a car.