Did you know that you can find and solve leetcode premium problems in lintcode.com with free access?
For example:
Premium: https://leetcode.com/problems/encode-and-decode-strings/description/
https://www.lintcode.com/problem/659/
For example:
Premium: https://leetcode.com/problems/encode-and-decode-strings/description/
https://www.lintcode.com/problem/659/
125. Valid Palindrome: https://leetcode.com/problems/valid-palindrome/description/
Idea from Neetcode: https://youtu.be/jJXJ16kPFWg
Idea from Neetcode: https://youtu.be/jJXJ16kPFWg
Title: 853. Car Fleet
Level: Medium
#stack
Very interesting problem. Try to solve it.
Watched beautiful solution from Neetcode
Level: Medium
#stack
Very interesting problem. Try to solve it.
Watched beautiful solution from Neetcode
🔥3
Title: 875. Koko Eating Bananas
Level: Medium
https://leetcode.com/problems/koko-eating-bananas/
#binary_search
Level: Medium
https://leetcode.com/problems/koko-eating-bananas/
#binary_search
🔥2
Title: 74. Search a 2D Matrix
Level: Medium
https://leetcode.com/problems/search-a-2d-matrix/description/
#binary_search
Level: Medium
https://leetcode.com/problems/search-a-2d-matrix/description/
#binary_search
🔥2
Title: 110. Balanced Binary Tree
Level: Easy
https://leetcode.com/problems/balanced-binary-tree/description/
#tree
Level: Easy
https://leetcode.com/problems/balanced-binary-tree/description/
#tree
👍1🤩1
Title: 572. Subtree of Another Tree
Level: Easy
https://leetcode.com/problems/subtree-of-another-tree/description/
Level: Easy
https://leetcode.com/problems/subtree-of-another-tree/description/
Title: 297. Serialize and Deserialize Binary Tree
URL: https://leetcode.com/problems/serialize-and-deserialize-binary-tree/
Level: Hard
Initially, it looked very difficult, as soon as I tried smth on my own and then watched solution from neetcode: https://neetcode.io/solutions/serialize-and-deserialize-binary-tree
Solution was very straightforward.
Ko'z qo'rqoq, qo'l botir.
#DFS #binary_tree
URL: https://leetcode.com/problems/serialize-and-deserialize-binary-tree/
Level: Hard
Initially, it looked very difficult, as soon as I tried smth on my own and then watched solution from neetcode: https://neetcode.io/solutions/serialize-and-deserialize-binary-tree
Solution was very straightforward.
Ko'z qo'rqoq, qo'l botir.
#DFS #binary_tree
Backtracking problems are almost always implemented using a depth-first search (DFS) strategy — but not all DFS is backtracking, and not all DFS problems require pruning or reversal (which backtracking does).