The O(n) Club2 Min Read dgtalbugonMarch 24, 2025 The O(n) Club: Middle of the Linked List—How to Outsmart a Conga Line (in Java) The O(n) Club: Middle of the Linked List—How to Outsmart a Conga Line (in Java) ⚡ TL;DR Need to find the middle of a singly linked list? Don’t… Discover More
The O(n) Club1 Min Read dgtalbugonMarch 24, 2025 The O(n) Club: Cheapest Flights Within K Stops: Layovers, Logic, and Code Turbulence The O(n) Club: Cheapest Flights Within K Stops – Layovers, Logic, and Code Turbulence ⚡ TL;DR Want the cheapest ticket from A to B with no… Discover More
The O(n) Club2 Min Read dgtalbugonMarch 23, 2025 The O(n) Club: Unique Binary Search Trees II: Recursion’s Party Trick The O(n) Club: Unique Binary Search Trees II — Recursion’s Party Trick ⚡ TL;DR Given n, build every possible BST using values 1 to n. Don’t… Discover More
The O(n) Club2 Min Read dgtalbugonMarch 23, 2025 The O(n) Club: Gas Station — Why Your Algorithm’s Tank Keeps Running Empty The O(n) Club: Gas Station — Why Your Algorithm’s Tank Keeps Running Empty ⚡ TL;DR Need to drive around a circle of gas stations without… Discover More
The O(n) Club2 Min Read dgtalbugonMarch 22, 2025 The O(n) Club: Single Element in a Sorted Array — When XOR Won’t Save You The O(n) Club: Single Element in a Sorted Array — When XOR Won’t Save You ⚡ TL;DR Given a sorted array where every element appears twice… Discover More
The O(n) Club2 Min Read dgtalbugonMarch 22, 2025 The O(n) Club: Counting Socially Awkward Provinces (LeetCode 547, With Less Anxiety) The O(n) Club: Counting Socially Awkward Provinces (LeetCode 547, With Less Anxiety) ⚡ TL;DR Stuck with a matrix where isConnected[i][j] tells… Discover More
The O(n) Club2 Min Read dgtalbugonMarch 21, 2025 The O(n) Club: Happy Number — When Integers Need Therapy The O(n) Club: Happy Number — When Integers Need Therapy ⚡ TL;DR Take a number. Replace it with the sum of the squares of its digits. Repeat.… Discover More
The O(n) Club1 Min Read dgtalbugonMarch 21, 2025 The O(n) Club: Coin Change 2: Counting Combos, Not Coins (Because Life’s Complicated Enough) The O(n) Club: Coin Change 2 — Counting Combos, Not Coins (Because Life’s Complicated Enough) ⚡ TL;DR Count the number of ways to make a given… Discover More
The Mutex Club2 Min Read dgtalbugonMarch 21, 2025 The Mutex Club: Getting Things Done with Future and Callable Introduction Imagine you politely tell a guest, “I’ve got to run,” but they stay for dessert. That’s exactly what Python’s… Discover More
The O(n) Club3 Min Read dgtalbugonMarch 20, 2025 The O(n) Club: Clone Graph (LeetCode 133) Without Spawning Infinite Twins The O(n) Club: Clone Graph (LeetCode 133) Without Spawning Infinite Twins ⚡ TL;DR You’ve got a connected undirected graph, and you need to… Discover More