about summary refs log tree commit diff
path: root/deepmind
AgeCommit message (Collapse)AuthorFilesLines
2020-01-22 Practice dijkstra's algorithmWilliam Carroll1-0/+26
Getting some practice with Python's heapq module (which I'm unsure if I used correctly) to do a priority-first-traversal of a graph: known as Dijkstra's algorithm.
2020-01-22 Complete which-appears-twiceWilliam Carroll1-0/+29
Solves the InterviewCake.com problem that asks us to write a function that returns the number, y, that occurs twice in a list, xs, where xs is an unsorted list of integers from 1..n with a length of n + 1.
2020-01-22 Complete reverse-linked-list problemWilliam Carroll1-0/+74
Completing the deceptively tricky reverse-linked-list problem from InterviewCake.com.
2020-01-22 Create org table of sorting algorithms and their efficiencyWilliam Carroll1-0/+6
This is just a small org table that I created to help me Fun fact: In Emacs, you can insert literal TAB character by pressing `C-q TAB`. For creating tables, using TAB characters feels perfectly acceptable. Perhaps the TAB name comes from TABle.
2020-01-22 Complete find-rotation-pointWilliam Carroll1-0/+55
Solves an InterviewCake.com problem that returns the index of the element in a list that should be the first element in that list. It's an exercise that's useful for seeing other applications of a binary search.
2020-01-22 Complete string permutations problemWilliam Carroll1-0/+56
Solves an InterviewCake.com problem that returns all of the permutations of a string input. The problem states that it's acceptable to assume that your input string will not have repeated characters, which is why using a Set is acceptable. I like this solution because it builds a permutations tree and then assembles all of the permutations by doing a DFT over that tree.
2020-01-22 Complete balanced binary tree problemWilliam Carroll1-0/+123
Supporting a function that returns true if a tree has no two leaf nodes with depth differences greater than 1.
2020-01-18 Complete practice algorithms from InterviewCake.comWilliam Carroll3-0/+161
While I've done these algorithms before, I'm preparing for an on-site with DeepMind, so I created a subdirectory called deepmind where I'm storing my second attempts at these problems. The idea of storing them in a second directory is to remove the urge to check my existing solutions that also exist in this repository.
2020-01-17 Add DeepMind subdirectoryWilliam Carroll1-0/+64
I need to prepare for my on-site with DeepMind, so I'll host some attempts to solve data structures and algorithms questions here.