Fundamentals14 / 42
Up next

Search within text

fn main() {
    let s = "hello.rs";
    println!("{} {} {}", s.contains("llo"), s.starts_with("he"), s.ends_with(".rs"));
}
What you're solving

contains, starts_with, ends_with