Skip to content


Solutions to Introduction to Algorithms Third Edition

📚 A crowdsourced work contributed from nice people all around the world.

Getting Started

This website contains nearly complete solutions to the bible textbook - Introduction to Algorithms Third Edition, published by Thomas H. Cormen, Charles E. Leiserson, Ronald L. Rivest, and Clifford Stein.

I hope to organize solutions to help people and myself study algorithms. By using Markdown (.md) files and KaTeX math library, this page is much more readable on portable devices.

"Many a little makes a mickle."


Thanks to the authors of CLRS Solutions, Michelle Bodnar (who writes the even-numbered problems) and Andrew Lohr (who writes the odd-numbered problems), @skanev, @CyberZHG, @yinyanghu, @Gutdub, etc.

Thanks to all contributors on GitHub, you guys make this repository a better reference!

Special thanks to @JeffreyCA, who fixed math rendering on iOS Safari in #26.

If I miss your name here, please tell me!


I build this website since I want to help everyone learn algorithms by providing something easy to read on mobile devices.

Therefore, if any adjustment is needed or you have the same motivation to contribute to this work, please don't hesitate to give me your feedback. You can press the "pencil icon" in the upper right corner to edit the content or open an issue in this repository. Your solution will be rebased after I review it and make some form modifications to your pull request.

There're lots of issues regarding to solutions in this repository, if you have time, please take a look and try to help people on the internet :)

Thank you very much, and I hope that everyone will learn algorithms smoothly.

How I Generate the Website?

I use the static site generator MkDocs and the beautiful theme Material for MkDocs to build this website.

As for rendering math equations, I use KaTeX, which is fast and beautiful.

I also add overflow-x: auto to prevent the overflow issue on small screen devices so that you can scroll horizontally in the math display equations.

More Information

For a clear commit history, I rebase my repository regularly. Therefore, if you have forked the repository before, consider re-forking it again.

For more information, please visit my GitHub.

Updated to this new page on April 13, 2018, at 04:48 (GMT+8).

Revised on July 21, 2019.


Licensed under the MIT License.