liyin2015 / python-coding-interview

A middle-to-high level open source algorithm book designed with coding interview at heart!
Apache License 2.0
2.13k stars 449 forks source link
algorithm algorithms algorithms-and-data-structures algorithms-explained book-series coding-interviews computer-science data-structures dsa googlecolab interview-preparation interview-questions leetcode leetcode-algorithms leetcode-problem-catalog python tree

Hands-on Algorithmic Problem Solving

A 100% open source one-stop coding interview prep book!


DSA · Python · LeetCode · Principles · Problem patterns


   
🔥  Among the top DSA repositories on GitHub



Contributing

The book is written in latex, and all contents except the code is located under Easy-Book folder. Feel free to send me pull requests to contribute contents. Before you start to improve the contents, it would be helpful to know the high-level structure of the book. Read How to contribute? for more details.

All contributors (with decent amount of contributions) will be listed as authors in the project.


About this book

book_structure

In short, this is a middle-to-high level algorithm book designed with cracking coding interviews at hearts. It offers a one-stop coding interview prep experience. The structure of the book:

Besides trying to make the content easy to follow, here summarizes the uniqueness of this book: (1) it offers Python source code that is tailored to be simple so that it would be natural for you to use in interviews (2) all the exercises and examples are from Leetcode problems so that you get to practise online (3) Classical algorithms are explained with design principles. No algorithm is magic. (Check out advanced graph algorithms as an example) (4) problem patterns to help you tackle coding interview questions topic by topic.


How did I come up with this book?

Preparing for the coding interview is not easy! Cracking the coding interview? Nearly impossible for most of us! Luck does play a role in the outcome. So, let's just treat it as a learning process and have some fun!

Computer Science is really not just computer science. It is a combination of all fields; our normal interview problems fall into the enumerative combinatorics and our computer vision mostly consists of Linear Algebra. What really matters is our passion to learn and the ability to apply this knowledge to solve real-life problems.

There are plenty of books out there focusing on either teaching algorithmic knowledge (Introduction to Algorithms, Algorithmic Problem Solving, etc) or introducing the interview process and solving interview problems(Cracking the Coding Interview, Coding Interview Questions, etc), but none of these books truly combine the two. This is a book designed to make up this role in the categorization. Principle, Pattern, and Leetcode Problems make up the core of this book.

This is NOT a book that provides hiring statistics for each company or gives the reader quick tricks in order to pass a few coding interviews. Its purpose is to show you the beauty of algorithmic problem solving in the hope that you will be more passionate and confident about software engineering; the interview questions just set up a playground where we strengthen what we learn.


For Readers

The whole book is compiled as pdf.

For readers, you can read the book as a whole or read chapters selectively following the below links.

Table of Contents


Warm Up: Abstract Data Structures and Tools

Get Started: Programming and Python Data Structures

Core Principles: Algorithm Design and Analysis

Advanced Algorithms

Problem Patterns

Note: everything is still in progress, so use it with caution.


Referring Books and Materials

Tools

Mocking Interviews

Practice is important. Schedule some mocking interviews with interviewing.io. If you cant manage to register, you can join us in discord server and ask peers for practice interview.


Community

Join me on discord server: https://discord.gg/ZXnSag7fMP, for a supportive community


Feedback

If you have ideas to improve the book, about formatting, more contents, or correct the errors, do not hesitate to let me know.

To cite this content, please use:


@misc{handsondsa,
    author       = {Li Yin},
    title        = {Hands-on Algorithmic Problem Solving},
    howpublished = {\url{https://github.com/liyin2015/python-coding-interview/}},
    year         = {2021}
}