Iterators can be collected into vectors! What is a Vector? A contiguous growable array type with heap-allocated contents. This video shows how to create a Vector with a macro, and using .collect()
We also look at how to print a data type using a function.
Check out the code from this video in the Rust playground: https://play.rust-lang.org/?version=stable&mode=debug&edition=2021&gist=bccb6485b31c24fa860fb33d6c00d272
View the Rust playlist here : https://youtube.com/playlist?list=PL38rDfx7QwKbB24PRKjwAGYuyXMwKMvQl
It would be amazing if you want to support my channel via Patreon:
Patreon := 🔗 https://www.patreon.com/join/3552586
#rustlang #rusttutorial #rustvector
Download
0 formats
No download links available.
Create Vector using collect() | print the data type | Rust Language | NatokHD