0%

Learn to program with Rust 2021 Edition, in an easy, step-by-step manner on Unix, the Linux shell, macOS, and the Windows command line.  As you read this book, you’ll build on the knowledge you gained in previous chapters and see what Rust has to offer.   

Beginning Rust starts with the basics of Rust, including how to name objects, control execution flow, and handle primitive types. You’ll see how to do arithmetic, allocate memory, use iterators, and handle input/output. Once you have mastered these core skills, you’ll work on handling errors and using the object-oriented features of Rust to build robust Rust applications in no time.

Only a basic knowledge of programming in C or C++ and familiarity with a command console are required. After reading this book, you’ll be ready to build simple Rust applications.

What You Will Learn

  • Get started programming with Rust
  • Understand heterogeneous data structures and data sequences
  • Define functions, generic functions, structs, and more
  • Work with closures, changeable strings, ranges and slices
  • Use traits and learn about lifetimes  

Who This Book Is For 

Those who are new to Rust and who have at least some prior experience with programming in general: some C/C++ is recommended particularly.

Table of Contents

  1. Cover
  2. Front Matter
  3. 1. Getting Started
  4. 2. Doing Arithmetic and Writing More Code
  5. 3. Naming Objects
  6. 4. Controlling Execution Flow
  7. 5. Using Data Sequences
  8. 6. Using Primitive Types
  9. 7. Enumerations and Matching
  10. 8. Using Heterogeneous Data Structures
  11. 9. Defining Functions
  12. 10. Defining Generic Functions and Types
  13. 11. Allocating Memory
  14. 12. Data Implementation
  15. 13. Defining Closures
  16. 14. Using Changeable Strings
  17. 15. Ranges and Slices
  18. 16. Using Iterators
  19. 17. Input/Output and Error Handling
  20. 18. Data Encapsulation
  21. 19. Using Traits
  22. 20. Object-Oriented Programming
  23. 21. Standard Library Collections
  24. 22. Ownership, Moves, and Copies
  25. 23. Borrowing and Lifetimes
  26. 24. More About Lifetimes
  27. Back Matter
18.219.236.62