The O(n) Club2 Min Read dgtalbugonMay 26, 2025 The O(n) Club: Counting Squares in Binary Matrices (Because Rectangles Are for Quitters) The O(n) Club: Counting Squares in Binary Matrices (Because Rectangles Are for Quitters) ⚡ TL;DR Counting all squares (not just the “big… Discover More
The O(n) Club1 Min Read dgtalbugonMay 26, 2025 The O(n) Club: Subarray Minimums & The Stack That Outsmarts Brute Force The O(n) Club: Subarray Minimums & The Stack That Outsmarts Brute Force ⚡ TL;DR Want to sum up the minimum of every contiguous subarray?… Discover More
The O(n) Club2 Min Read dgtalbugonMay 25, 2025 The O(n) Club: Delete and Earn – When House Robber Goes Full Arcade The O(n) Club: Delete and Earn – When House Robber Goes Full Arcade ⚡ TL;DR Every time you delete a number, you also assassinate its… Discover More
The O(n) Club3 Min Read dgtalbugonMay 25, 2025 The O(n) Club: Detecting 132 Patterns Faster Than Your Interviewer Can Blink The O(n) Club: Detecting 132 Patterns Faster Than Your Interviewer Can Blink ⚡ TL;DR Find three numbers in an array that say, “Look, I zigged… Discover More
The O(n) Club3 Min Read dgtalbugonMay 24, 2025 The O(n) Club: Pacific Atlantic Water Flow’s Reverse-DFS Party Trick The O(n) Club: Pacific Atlantic Water Flow’s Reverse-DFS Party Trick ⚡ TL;DR Which cells in a height matrix can get their water to both… Discover More
The O(n) Club2 Min Read dgtalbugonMay 24, 2025 The O(n) Club: Largest Divisible Subset: DP, Java, and Chaos Prevention The O(n) Club: Largest Divisible Subset—DP, Java, and Chaos Prevention ⚡ TL;DR This problem is basically “who can divide whom at the nerd… Discover More
The O(n) Club3 Min Read dgtalbugonMay 23, 2025 The O(n) Club: Asteroid Collision: Simulate, Stack, Survive (LeetCode 735) The O(n) Club: Asteroid Collision—Simulate, Stack, Survive (LeetCode 735) ⚡ TL;DR Bunch of asteroids, each moving left or right. When they… Discover More
The O(n) Club2 Min Read dgtalbugonMay 23, 2025 The O(n) Club: Distinct Subsequences, or How to Skip Letters Like a Pro (and Keep Your Sanity) The O(n) Club: Distinct Subsequences, or How to Skip Letters Like a Pro (and Keep Your Sanity) ⚡ TL;DR Want the number of ways to get t as a… Discover More
The O(n) Club2 Min Read dgtalbugonMay 22, 2025 The O(n) Club: How Many Ways Can You Lose Count? (A Java Dev’s Guide to Combination Sum IV) The O(n) Club: How Many Ways Can You Lose Count? (A Java Dev’s Guide to Combination Sum IV) ⚡ TL;DR You want to count the number of… Discover More
The O(n) Club2 Min Read dgtalbugonMay 22, 2025 The O(n) Club: Remove Element — How to Clean Arrays Without Panic or Pain The O(n) Club: Remove Element — How to Clean Arrays Without Panic or Pain ⚡ TL;DR LeetCode #27 in plain English: Pretend you actually like… Discover More