Exerpad
🔥 0
0 XP
Exercise 5 · Chapter: VectorsRequired+50 XP

List Length

Create a vector with 5 items: "a", "b", "c", "d", "e". Then print its length in this exact format:

Expected output:

Length: 5

Hints:

  • Use .len() to get the number of items
  • Use println!("Length: {}", letters.len()) to format the output
rust
fn main() {
}
Output
Run your code to see the output here.