add func that returns total travel cost