
Java Recursion Limit and Stack Overflow: The Interview Guide
Java has no recursion limit you can set. Learn the 1MB JVM stack default, when StackOverflowError fires, and the interview-correct fix.
Page 3 of 61 · Ideas for curious minds in tech.
Back to the archive
Java has no recursion limit you can set. Learn the 1MB JVM stack default, when StackOverflowError fires, and the interview-correct fix.

Python integers never overflow. But floor division, sys.maxsize, and float precision are three traps that catch engineers in Python coding interviews.

Every Python string method you need for coding interviews: time complexity, gotchas, and patterns that win. From split/join to ord/chr.

Python's recursion limit catches you in coding interviews. Learn the real ceiling, when to raise it, and when iterative DFS is the safer default.

A tail call is the last operation before a function returns. Learn the one rule, the accumulator pattern, and which languages actually optimize it.

The return address tells the CPU where to resume after a function call. Learn how it powers recursion space, stack overflows, and tail call optimization.
A stack frame is a private memory block for each function call. See what's inside, how frames chain together, and why depth equals recursion space complexity.

Call stack vs heap memory: understand where variables live, why recursion consumes stack frames, and how to analyze space complexity in coding interviews.

A weak reference lets the GC reclaim an object even if a cache still holds it. Covers Python weakref, Java WeakHashMap, and JavaScript WeakMap.

Python reference cycles fool reference counting into keeping dead objects alive. Here's how the cyclic GC finds them, and why weak references fix it.

Garbage collection pauses stop every thread to reclaim memory. Learn why stop-the-world happens, minor vs major GC, ZGC, and what it means for your p99.

A memory pool pre-allocates a contiguous block for O(1) allocation. Zero per-object overhead, no fragmentation, and how nginx and Python use them.

A free list data structure keeps freed memory blocks in a private pool for O(1) reuse. Learn how it works, where it runs, and why it appears in interviews.

A circular buffer is a fixed-size ring array with O(1) enqueue and dequeue. Learn the full/empty bug fix, implementation in Python, and LeetCode patterns.

A doubling array copies itself into a 2x block on resize. Here's why append is amortized O(1), not just O(1), and when the difference matters in interviews.

A Python generator yields values one at a time in O(1) space. Learn how yield works, when to use generators in interviews, and the patterns that matter.

What is an iterator? A stateful cursor that yields one value at a time. Learn the protocol, lazy evaluation, O(1) space, and LeetCode interview patterns.

Short-circuit evaluation skips the right operand the moment the result is certain. How && and || work, null guards, and the && vs & bug in Java.

Python lazy evaluation explained: why map() returns an object, when generators beat lists, and the four iterator bugs that show up in coding interviews.

What is a thunk? A zero-argument function that defers computation. Learn how thunks power lazy evaluation, memoization, and Redux middleware in coding interviews.

Python's recursion limit defaults to 1,000 frames. Understand why it exists, what RecursionError means, and how to fix deep recursion permanently.

Recursion depth is the number of active stack frames. Learn why Python limits it to 1,000, how it drives space complexity, and how to fix it.

What is a side effect in programming? Any state change a function makes outside its own scope, and why it causes your hardest coding interview bugs.

Idempotency makes retry-safe APIs and distributed systems possible. Learn what it means, how HTTP methods split on this line, and when to use idempotency keys.