1. # Combinatorial Generation For Coding Interviews With Examples In Python

What you need to know to solve basic combinatorial generation problems you might encounter on coding interviews, with plenty of examples in Python.

Tags:
2. # From An Iterator of Iterators to Cantor's Paradise: A Deep Dive Into An Interview Question

A deep dive into flattening an iterator of iterators and a segue into set theory and some of its theorems based on the solutions to this problem, inspired by a coding interview question.

Tags:
3. # Generating All Balanced Parentheses: A Deep Dive Into An Interview Question

A deep dive into the generation of balanced parentheses, inspired by a coding interview question.

Tags:
4. # A Review of Basic Algorithms and Data Structures in Python - Part 1: Graph Algorithms

A quick review of basic graph algorithms and related data structures, with minimal implementations and unit tests provided in Python.

Tags:
5. # Fun With Python Coroutines: Generating Permutations

A very short post on having fun with coroutines to generate all permutations of a given list.

Tags:
6. # Understanding Recurrence Relations Using Automata, Python Code, And Javascript Visualizations

Recurrence relations are very often taught in first- or second-year computer science and discrete mathematics courses. This post takes a somewhat different and more visual approach to understanding linear recurrences and solving them by drawing the link between linear recurrences, automata, and matrices, using the problem of generating all domino-tilings of a board as the springboard. Code in Python and visualizations in JavaScript are used to demonstrate the ideas.

Tags:
7. # Turing Recognizability of Turing Machines That Accept All Strings

A proof that the set of encodings of Turning machines that accept all strings is not Turing-recognizable.

Tags:
8. # Combinatorial Generation Using Coroutines With Examples in Python

Approaching combinatorial generation algorithms using coroutines, with examples in Python. Inspired by Knuth's work in his volume 4 of The Art of Computer Programming, as well as his "Deconstructing Coroutines" paper, co-written with Frank Ruskey.

Tags:
9. # Multilinear Representation of Boolean Functions

Algorithm to compute the multilinear representation of a boolean function given its truth table.

Tags:
10. # Line Intersecting Maximal Number of Circles (Circle "Stabbing" Problem)

Developing an algorithm to find a line that intersects a maximal number of circles, given a set of circles. Based on an ACM ICPC regional competition problem.

Tags:
11. # Expected Running Time of Two Randomized Sort Algorithms (ACM ICPC 2013 PACNW Regional)

Computing the expected running time of two randomized sort algorithms for a given input array. This problem appeared in ACM ICPC 2013 PACNW regional competition.

Tags:
12. # Pattern Matching in Fibonacci Words (ACM ICPC World Finals 2012)

A discussion of calculating the number of occurrences of a given pattern in Fibonacci words, with a Java solution. Problem from the 2012 ACM ICPC world finals.

Tags:
13. # Fibonacci Primitive Roots of Primes (Project Euler)

A problem on finding primes with Fibonacci primitive roots, from Project Euler and my Python solution.

Tags:
14. # Common Substring Permutation

Short post on a simple problem on common subsequence permutations with a neat one-line Python solution.

Tags:
15. # Hundred Prisonors and a Room With a Light Switch

A hundred prisoners are given a challenge that might set them free. See if you can solve the puzzle involving a light switch and help them gain their freedom.

Tags:
16. # Interview Question: All Possible Products of a List of Primes

Interview question to list all possible products of a list of primes, with two Python solutions and a short discussion of the problem.

Tags:
17. # Problem-Solving Lessons From George Pólya

What I learned from Newman's selections of Pólya's How to Solve It, the influential and beautifully written book on problem-solving techniques and heuristics.

Tags:
18. # Interview Question: Fair and Unfair Coins and Bayes' Theorem

Interview question to infer the probability of an fair and unfair coins after a certain number of coin tosses using Bayes' theorem.

Tags:
19. # Interview Question: Fairness from Unfairness and Randomness Extraction

Interview question to use an unfair coin to simulate a fair one. The question is the same as extracting randomness from an unfair Bernoulli process. A Python implementation is given.

Tags:
20. # Interview Question: Grouping Words Into Anagrams

Simple Python solution to interview question to group words into anagrams.

Tags: