Tech Challenge
2026-09-15
🦀
Daily Tech Challenge
Rust
medium
Question 1 of 5
What does this program print, probing a Vec with contains, starts_with and ends_with?
Example
fn main() {
let v = vec![10, 20, 30, 40];
let out = [
v.contains(&20),
v.starts_with(&[20, 30]),
v.ends_with(&[40]),
v.starts_with(&[]),
];
println!("{:?}", out);
}Tuesday, September 15, 2026 · A new challenge drops every day