cargo fmt
This commit is contained in:
@@ -41,7 +41,11 @@ fn main() {
|
||||
// Hint: .to_uppercase() is a method on `str` which returns a String
|
||||
|
||||
let words = vec!["autobot", "beach", "car", "decepticon", "energon", "frothy"];
|
||||
let transformed = words.into_iter().filter(|w| !w.contains("h")).map(|w| w.to_uppercase()).collect::<Vec<String>>();
|
||||
let transformed = words
|
||||
.into_iter()
|
||||
.filter(|w| !w.contains("h"))
|
||||
.map(|w| w.to_uppercase())
|
||||
.collect::<Vec<String>>();
|
||||
println!("Transformed: {:?}", transformed);
|
||||
|
||||
// Challenge:
|
||||
|
||||
Reference in New Issue
Block a user