dsa2 min read
Minimum Size Subarray Sum [Medium] — Sliding Window
Find the smallest contiguous subarray with sum >= target using the shrinkable sliding window technique.
Read →
webcoderspeed.com
1276 articles
Find the smallest contiguous subarray with sum >= target using the shrinkable sliding window technique.
Find all integers that appear twice using index-sign-marking trick in O(n) time and O(1) extra space.
Decode a run-length-encoded string like "3[a2[bc]]" = "abcbcabcbcabcbc" using a stack for nested brackets.
Find all unique combinations that sum to target where each number may be used once, skipping duplicates at each recursion level.
Search for a word in a 2D grid using DFS backtracking with in-place visited marking.