Features of Rust compared with C++

Rust and C++ have roughly analogous functionality although they often go about it in different ways.

Rust benefits from learning what works in C / C++ and what doesn’t and indeed has cherry-picked features from a variety of languages. It also enjoys a cleaner API in part because things like Unicode dictate the design.

This section will cover such topics as types, strings, variables, literals, collections, structs, loops and so on. In each case it will draw comparison between how things are in C/C++ and how they are in Rust.

Also bear in mind that Rust compiles to binary code and is designed to use C binaries and be used by C binaries. Therefore the generated code is similar, but it is different as source.