Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Creating an associative array in Rust

I was looking for the way to create an associative array in the documentation but didn't find anything. So how do I create an associative array in Rust?

like image 530
Incerteza Avatar asked Oct 22 '14 00:10

Incerteza


1 Answers

What you know as an associative array is also known by some other names, such as a dictionary or a map.

In Rust, it’s called a map, and is epitomised in the HashMap type.

like image 135
Chris Morgan Avatar answered Oct 29 '22 10:10

Chris Morgan