Arrays & Strings Complete — 100-Problem Master Cheatsheet
Master cheatsheet of all 100 Arrays & Strings problems: patterns, time/space complexity, and MAANG company tags in one place.
1575 articles
Master cheatsheet of all 100 Arrays & Strings problems: patterns, time/space complexity, and MAANG company tags in one place.
Master Pascal's Triangle (LeetCode 118 & 119) by understanding the binomial coefficient connection, the row-by-row DP pattern, space-optimized O(k) single-row generation, and five hidden mathematical properties that show up in Unique Paths, Coin Change, and beyond.
Master LeetCode 242 Valid Anagram with three approaches — sort O(n log n), 26-element frequency array O(n)/O(1), and HashMap O(n)/O(k). Includes a visual dry run, the critical Unicode follow-up, and the direct connection to Group Anagrams (LC 49).
Reverse a character array in-place using two pointers. O(n) time, O(1) space. The fundamental two-pointer swap pattern.
Find the index of the first non-repeating character in a string. Two-pass O(n) solution with a 26-array or HashMap.