added method to remove duplicated indexes from cities array