Duplicated code to a method
Added roads lenght calculations