https://leetcode.com/problems/find-elements-in-a-contaminated-binary-tree/description/
Is number in a tree 2*v+(1L, 2R)? #medium #bfs #dfs
Is number in a tree 2*v+(1L, 2R)? #medium #bfs #dfs
👍1🔥1
https://leetcode.com/problems/recover-a-tree-from-preorder-traversal/description/
Recover binary tree from depth-dashes string #hard #stack
Recover binary tree from depth-dashes string #hard #stack
👍2🔥1
https://leetcode.com/problems/construct-binary-tree-from-preorder-and-postorder-traversal/description/
Tree from preorder & postorder #medium #stack
Tree from preorder & postorder #medium #stack
🔥2👍1
https://leetcode.com/problems/most-profitable-path-in-a-tree/description/
Max Alice path down, Bob up in tree #medium #dfs
Max Alice path down, Bob up in tree #medium #dfs
👍2🔥1
https://leetcode.com/problems/number-of-sub-arrays-with-odd-sum/description/
Count odd sum subarrays #medium #prefix_sum
Count odd sum subarrays #medium #prefix_sum
👍1🔥1
https://leetcode.com/problems/maximum-absolute-sum-of-any-subarray/description/
Max abs of subarray sum #medium #prefix_sum
Max abs of subarray sum #medium #prefix_sum
👍1🔥1
https://leetcode.com/problems/length-of-longest-fibonacci-subsequence/description/
Longest sequence a, b, a + b #medium #dynamic_programming
Longest sequence a, b, a + b #medium #dynamic_programming
👍1
https://leetcode.com/problems/shortest-common-supersequence/description/
Shortest string with both subsequences #hard #lcs #dp
Shortest string with both subsequences #hard #lcs #dp
👍1🔥1
https://leetcode.com/problems/apply-operations-to-an-array/description/
If a[i] == a[i + 1], a[i] *= 2, a[i + 1] = 0 #easy
If a[i] == a[i + 1], a[i] *= 2, a[i + 1] = 0 #easy
👍1🔥1
https://leetcode.com/problems/merge-two-2d-arrays-by-summing-values/description/
Merge two ascending [key, value] lists #easy
Merge two ascending [key, value] lists #easy
👍2
Number as sum of distinct powers of 3 #medium #math
https://leetcode.com/problems/check-if-number-is-a-sum-of-powers-of-three/description/
https://leetcode.com/problems/check-if-number-is-a-sum-of-powers-of-three/description/
👍1🔥1
https://leetcode.com/problems/find-missing-and-repeated-values/description/
Missing and repeated in 1..n array #medium #math
Missing and repeated in 1..n array #medium #math
🔥1
Min diff primes pair in left..right #medium #math
https://leetcode.com/problems/closest-prime-numbers-in-range/
https://leetcode.com/problems/closest-prime-numbers-in-range/
👍3
Min 'W' flips to make k 'B' #medium #sliding_window
https://leetcode.com/problems/minimum-recolors-to-get-k-consecutive-black-blocks/description
https://leetcode.com/problems/minimum-recolors-to-get-k-consecutive-black-blocks/description
👍2
Count cycling alterating k-subarrays #medium #two_pointers
https://leetcode.com/problems/alternating-groups-ii/description
https://leetcode.com/problems/alternating-groups-ii/description
👍3
Substring with all vowels and k others #medium #two_pointers
https://leetcode.com/problems/count-of-substrings-containing-every-vowel-and-k-consonants-ii/description/
https://leetcode.com/problems/count-of-substrings-containing-every-vowel-and-k-consonants-ii/description/
👍2
Max positive count or negative count #easy #binary_search
https://leetcode.com/problems/maximum-count-of-positive-integer-and-negative-integer/description/
https://leetcode.com/problems/maximum-count-of-positive-integer-and-negative-integer/description/
👍1🔥1