fn format_zip_code(zip_codes: &[String]) -> String {
    match zip_codes.len() {
        0 => "".to_string(),
        1 => format!(" ({})", zip_codes.first().unwrap()),
        _ => format!(
            " ({}-{})",
            zip_codes.first().unwrap_or(&"".to_string()),
            zip_codes.last().unwrap_or(&"".to_string())
        ),
    }
}
/// format the zone's zip code
/// if no zipcode, we return an empty string
/// if only one zipcode, we return it between ()
/// if more than one we display the range of zips code
///
/// This way for example Paris will get " (75000-75116)"
///
/// ruthlessly taken from mimir
format the zone's zip code
if no zipcode, we return an empty string
if only one zipcode, we return it between ()
if more than one we display the range of zips code

This way for example Paris will get " (75000-75116)"

ruthlessly taken from mimir
format the zone ' s zip code if no zipcode we return an empty string if only one zipcode we return it between () if more than one we display the range of zips code This way for example Paris will get " ( 75000 - 75116 ) " ruthlessly taken from mimir
fn format_zip_code(zip_codes: &[String]) -> String {
    match zip_codes.len() {
        0 => "".to_string(),
        1 => format!(" ({})", zip_codes.first().unwrap()),
        _ => format!(
            " ({}-{})",
            zip_codes.first().unwrap_or(&"".to_string()),
            zip_codes.last().unwrap_or(&"".to_string())
        ),
    }
}
fn format_zip_code ( zip_codes : & [ String ] ) -> String { match zip_codes . len ( ) { 0 => " " . to_string ( ) , 1 => format ! ( " " zip_codes first ( ) unwrap ( ) ) , _ => format ! ( " " zip_codes first ( ) unwrap_or ( " " to_string ( ) ) zip_codes last ( ) unwrap_or ( " " to_string ( ) ) ) , } }
format the zone's zip code
if no zipcode, we return an empty string
if only one zipcode, we return it between ()
if more than one we display the range of zips code
format the zone ' s zip code if no zipcode we return an empty string if only one zipcode we return it between () if more than one we display the range of zips code
zip_codes
&[String]