Skip to Main Content
The Rust Programming Language
book

The Rust Programming Language

by Steve Klabnik, Carol Nichols
July 2018
Intermediate to advanced content levelIntermediate to advanced
552 pages
13h 50m
English
No Starch Press
Content preview from The Rust Programming Language

8COMMON COLLECTIONS

image

Rust’s standard library includes a number of very useful data structures called collections. Most other data types represent one specific value, but collections can contain multiple values. Unlike the built-in array and tuple types, the data these collections point to is stored on the heap, which means the amount of data does not need to be known at compile time and can grow or shrink as the program runs. Each kind of collection has different capabilities and costs, and choosing an appropriate one for your current situation is a skill you’ll develop over time. In this chapter, we’ll discuss three collections that are used very ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Programming WebAssembly with Rust

Programming WebAssembly with Rust

Kevin Hoffman
Programming Rust

Programming Rust

Jim Blandy, Jason Orendorff
The Rust Programming Language, 2nd Edition

The Rust Programming Language, 2nd Edition

Steve Klabnik, Carol Nichols

Publisher Resources

ISBN: 9781492067665Errata Page