I built a reference cookbook of algorithms and data structures for contest problem solvers. It’s written in the Rust programming language, as I believe it’s ideally suited to the task. For more info, please check out the repository at github.com/EbTech/rust-algorithms.

Codeforces Rust

While I think Rust is no more difficult than C++ from a beginner’s point of view, for experienced developers it may require substantially adjusting one’s mental model. If you like to learn from small but dense toy problems, contests can serve as a useful playground.

Unfortunately, it’s hard to get started when there are still so few examples of Rust code in contest programming. This project seeks to remedy the situation. Note that it’s not meant to act as a full-fledged general-purpose library. Contest problems often require understanding an algorithm so well that you can dig in and make subtle modifications to make it suitable for a brand new problem. Therefore, in this setting, one ought not to rely on blackbox implementations. Instead, I try to distill each algorithm into its simplest possible form, so that you can read over the code, understand it, and augment it to suit your needs.

Rust and Codeforces represent two of my favorite technology communities, which I hope to bring a little bit closer together. If you’re a Rust programmer interested in honing your technical interview skills or solving cool programming puzzles, you might enjoy Codeforces. If you’re a Codeforces member and find that debugging is a huge time drain, Rust’s emphasis on safety may give you a competitive edge. In either case, I hope this reference will help ease the learning curve for you. I’m still learning too, so suggestions are always welcome.