Create vector of strings from array of str using from_iter



examples/vectors/create-from-iter/src/main.rs
fn main() {
    let animals = Vec::from_iter(
        ["mouse", "elephant", "cat", "dog", "giraffe"].map(|animal| animal.to_owned()),
    );

    println!("animals: {:?}", animals);
}

animals: ["mouse", "elephant", "cat", "dog", "giraffe"]