I’ve just started learning rust and have simple problem.
I have a simple slice of string slices like:
let a : &[&str] = &[“hello”, “world”];
I want to use iterator with it (filter it using some condition) and then collect results into Vec of string slices.
Basically help me to compile code in play rust link. I understand the error and I can fix it with longer code like creating and populating Vec by myself, but I want to understand iterators API so I hope there should be simple solution