Giter Club home page Giter Club logo

ctci_python's Introduction

Cracking the Coding Interview (6th edition) Python Solutions

Existing Python solutions can be found officially here and user-created here

Current progress

Nr. Chapter Done Total Ommited
1 Array and String 9 9
2 Linked Lists 8 8
3 Stacks and Queues 6 6 1
4 Trees and Graphs 12 12
5 Bit Manipulation 8 8
6 Math and Logic Puzzles 10 10 4
7 OO Design 0 12
8 Recursion and DP 14 14
9 System Design 0 8
10 Sorting and Searching 9 11 1
11 Testing 4 6 4
12 C/C++ 11 11 11
13 Java 0 8
14 Databases 0 7
15 Threads and Locks 0 7
16 Moderate 26 26 1
17 Hard 26 26

Running the solutions

For convenience, the project has a setup.py that specifies a package This can be installed locally in the python (virtual)environment by using

pip install -e .

Problems can be run by running the file, most should have a main method.

python p16_20.py

Some highlights

Langton's ant (Chapter 16, Problem 22)

Result pattern

An interesting example of emergent patterns from simple rules. Raise the number of iterations in the code to see more of the "highway" form.
For more information, check the wikipedia link.

Tree visualising in VS Code

Example tree

This requires graphviz to be installed locally and the extension added to VS Code.
The one used in the screenshot above can be found here.

ctci_python's People

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.