Parse a Boolean String Value: Truthy/Falsy Conventions
5 min read Parse a Boolean String Value: Truthy/Falsy Conventions Across Languages “Parse a string into a boolean value” sounds trivial — just […] Read article
5 min read Parse a Boolean String Value: Truthy/Falsy Conventions Across Languages “Parse a string into a boolean value” sounds trivial — just […] Read article
6 min read Print All Permutations of a String: Recursion, Backtracking, and Iterative Heap’s Algorithm Generating all permutations of a string is a Read article
2 min read Write a function to find the longest palindrome in a string. 2026 Update: Longest Palindrome — Character Frequency Approach There Read article
6 min read Prime Numbers: Sieve of Eratosthenes, Trial Division, and the Miller-Rabin Test Prime number problems appear at FAANG interviews, fintech screens, Read article
5 min read Parse Phone Numbers Without a Country Code: Heuristic Detection “Given a list of phone numbers in mixed formats, identify which Read article
5 min read The 100 Doors Puzzle: Parity, Perfect Squares, and Why Divisor Counts Matter The 100 doors puzzle is a beautiful number-theory Read article
5 min read The Two-Eggs (Light Bulbs) Problem: 80-Floor Building, Optimal Strategy, and DP “You have 2 eggs and a 100-floor building. Find Read article
5 min read Count Negative Numbers in a Sorted Matrix: Staircase Search and Binary Search Counting negative numbers in a row-and-column-sorted matrix (LeetCode Read article
5 min read Return True with Probability p/q: Sampling Without Bias “Given a function that returns a uniform random value, write a function Read article
5 min read The Bridge Crossing Puzzle: Four People, One Flashlight, 17 Minutes The bridge-crossing puzzle is a classic interview question that appears Read article
6 min read Fair Server Scheduling: Round Robin, Weighted Fair Queueing, and Modern Approaches “Design a server that processes a fair number of Read article
5 min read Multiply Two Integers Without Using Multiplication: Russian Peasant, Bit Shifts, Recursion “Multiply two integers without using the * operator” is Read article
6 min read Detect a Cycle in a Linked List: Floyd’s Algorithm and Cycle Entry Point Detecting a cycle in a linked list Read article
5 min read The Fruit Jar Labeling Puzzle: Three Mislabeled Jars, One Fruit Picked The fruit jar labeling puzzle is a famous lateral-thinking Read article
5 min read The Burning Ropes Puzzle: Measure 45 Minutes with Two Ropes That Burn Unevenly The burning ropes puzzle is a famous Read article