Skip to content

Study by subject

Coding interviews

For a coding interview you learn complexities, data structures, algorithm patterns and design questions by heart. Lumi asks them back until you can produce them without freezing at the whiteboard.

How to turn this subject into cards

Make one card per data structure with the cost of each operation, and one card per algorithm pattern, like two pointers or the sliding window, with the sign that lets you recognise it. For design, one card per component, like the cache, the message queue or the load balancer, with its role. The trap is solving a hundred problems without ever fixing the patterns, and stumbling on the same kind of question. With Lumi you describe the solution from memory before seeing it, and that recall builds the reflex (Roediger and Karpicke, 2006). Come back to a pattern several days apart, and always say the complexity out loud (Cepeda et al., 2006).

What you need to know by heart

  • Time and space complexity of usual operations, Big O notation.
  • Data structures, array, linked list, stack, queue, hash table, tree, graph.
  • Algorithm patterns, two pointers, sliding window, recursion, dynamic programming.
  • Classic sorts and traversals, with their cost.
  • The building blocks of design questions, cache, message queue, load balancer, database.

How Lumi helps you remember it

You teach your cards to Lumi, complexities, structures, patterns, design. It forgets over time, like you do, then quizzes you right before you would forget. As the interview approaches, the Mist settles over what you know less well, dynamic programming or graphs for example, and Lumi asks that first. You arrive recognising the pattern straight away.

Example cards

Three cards the way you would write them, with the answer Lumi expects.

  • What is the complexity of binary search?

    O(log n) on a sorted array.

  • Which structure works on a last in, first out basis?

    The stack.

  • What sign points to a sliding window?

    A question about a contiguous subarray or substring to optimise.

Example card

Try it, Lumi turns it into fill in the blank questions in your browser.

study-card.txt

Coding interviews · teach this card to Lumi

Binary search on a sorted array runs in O(log n) time. A hash table gives average access in O(1) time. A stack works on a last in, first out basis. A breadth first search of a graph uses a queue.

Lumi’s question

Binary search on a sorted array runs in O(_____) time.

Pick the missing word

1 / 4
All subjects
Preview

Answer right to light Lumi up

Its lamp fades when a fact slips away.

Frequently asked questions

How many problems should I solve before an interview?
The number matters less than what you retain from them. After each problem, put the pattern on a card and let Lumi ask it back so it stays.
How do I revise system design questions?
One card per component with its role and trade offs. Lumi asks them back, and you then put the answers together out loud.
Does Lumi replace practising on a problem platform?
No, the two work together. The platform gives you the problems, and Lumi makes you retain the complexities and patterns that come out of them.

Read next

Sources

  1. Roediger, Karpicke (2006). Test-enhanced learning. Taking memory tests improves long-term retention. Psychological Science, 17(3). doi.org/10.1111/j.1467-9280.2006.01693.x
  2. Cepeda, Pashler, Vul, Wixted, Rohrer (2006). Distributed practice in verbal recall tasks. A review and quantitative synthesis. Psychological Bulletin, 132(3). doi.org/10.1037/0033-2909.132.3.354

Teach this to Lumi

Give Lumi your coding interviews notes, it gives them back as questions at the right moment.

Coming soon on theApp StoreFree with 3 cards a week. No ads.