fn count_utf16(s: &str) -> usize {
    let mut utf16_count = 0;
    for &b in s.as_bytes() {
        if (b as i8) >= -0x40 {
            utf16_count += 1;
        }
        if b >= 0xf0 {
            utf16_count += 1;
        }
    }
    utf16_count
}
/// Counts the number of utf-16 code units in the given string.
Counts the number of utf-16 code units in the given string.
Counts the number of utf - 16 code units in the given string .
fn count_utf16(s: &str) -> usize {
    let mut utf16_count = 0;
    for &b in s.as_bytes() {
        if (b as i8) >= -0x40 {
            utf16_count += 1;
        }
        if b >= 0xf0 {
            utf16_count += 1;
        }
    }
    utf16_count
}
fn count_utf16 ( s : & str ) -> usize { let mut utf16_count = 0 ; for & b in s . as_bytes ( ) { if ( b as i8 ) >= - 0x40 { utf16_count += 1 ; } if b >= 0xf0 { utf16_count += 1 ; } } utf16_count }
Counts the number of utf-16 code units in the given string.
Counts the number of utf - 16 code units in the given string .
s
&str