4 ms·
i didn't mean rust didn't have dynamic sized arrays, i even mentionned Vec in my comment. I am indeed a beginner in rust, and i was surprised by the completely
by bsaul 7y ago
i didn't mean rust didn't have dynamic sized arrays, i even mentionned Vec in my comment.
I am indeed a beginner in rust, and i was surprised by the completely different syntax & types for arrays and Vec... I read about it afterward and get the reason for it, but that's the first time i encountered that peculiarity in a language..
- nindalf 7y agoI think you were downvoted because your comment appeared to be making an incorrect assertion confidently, rather than asking a question. > funny how rust doesn't seem to let you easily work with dynamically sized array Could instead have been > why did the author choose a hashmap?
- brundolf 7y agoA Rust Vec is very similar, if I recall correctly, to a C++ vector. It can basically be used like a List but is implemented underneath as an automatically dynamically-sizing array.
- PudgePacket 7y agoThat's fair, many languages will only have Vecs, and will call them arrays, so it can cause confusion coming to Rust :)