20 ms·
IMHO: Learn both but start with Rust. Rust forces you to think about memory management topics (memory lifetimes and ownership) which you will also need to know
by flohofwoe 6y ago
IMHO: Learn both but start with Rust. Rust forces you to think about memory management topics (memory lifetimes and ownership) which you will also need to know about in C++, but in C++ you are entirely on your own so it's easier to "slip into" bad memory management practices (which you would need to unlearn again when moving from C++ to Rust).
You should also include C in the mix (very different from C++(!!) that's why "C/C++" is a bit shunned upon by some people), because Rust or C++ are often overkill. If you're tackling Rust and C++ anyway (which is essentially a lifetime task), learning C on the side is literally a "weekend project" ;)
Just remember that C and C++ are not as similar as many people believe, they are different languages with different goals and a different philosophy.