< Ownership taught me data flow >
In Python, you pass objects around without thinking about who "owns" them.
In Rust, you have to be explicit.
This applies to other languages as well. The more you learn about other languages, the better you became in others just because of things like this.
Now when I write Python, I think a bit more about data ownership ("does this function own the right to mutate the caller’s list?" for example).
< Working with the Result type taught me stronger error handling patterns >
Python lets you ignore exceptions which might blow up at runtime.
Rust's Result<T, E> forces you to handle errors explicitly.
Now my Python code has stronger error handling because I think more clearly about failure paths upfront.
< The borrow checker taught me to read compiler errors >
Rust's compiler is famously strict, but because of that also famously helpful.
"Fighting the borrow checker" taught me to read error messages more closely.
That skill transfers everywhere.
< Pattern matching taught me to think in cases >
Rust's match is exhaustive - you handle every case or the code won't compile.
I'm running a cohort for Python developers who want this perspective shift. 6 weeks, building a real project (JSON parser) from scratch, learning concepts + good program design.
Next cohort starts in 4 weeks. Check out more detail -> https://scriptertorust.com/
@bbelderbos I gained a lot from C++ library design, especially the STL (the design, not the implementation!)
So much goes into designing truly generic containers and algorithms, deciding what's a method, what's a free function, what your interfaces look like, and what doesn't belong in the type at all...
Python implementations are naturally entirely different, but the principles still apply.