Is there a way to add own test cases and see expected output on Leetcode? I feel like this would be helpful feature because the examples provided generally cover few edge cases only. I think I've seen some one create test case tree via comments and the run test for that. ex: check if following is valid BST, resulting in false /* 1 / \ 2 3 */
This is one of the hurdles that make a huge difference in your ability to solve problems. Take some time to focus on recursion. Look at various simpler recursive problems until you can start to see patterns and visualize how it works. Once you can visualize recursion it will be a quantum leap forward in your programming skills. There are a lot of milestones like this, just try not to get discouraged and keep finding material on the subject until it clicks. You'll eventually have enough practice or find the perfect lesson for you that will make it 'click'.
your voice is so pleasant to our ears and your way to explain the approach and code is absolutely fantastic. Thanks for the content you gave us !😊😇
Well explained. Thank you!
so concise!
Nice explanation sir ❤❤
Fire content :)
By looking at your code :
T(n) = 2 T(n/2) + k, It gives nlog(n) time complexity.
Please correct me if I am wrong
So 1 is for the root node of the subTree / main tree ?
Is there a way to add own test cases and see expected output on Leetcode? I feel like this would be helpful feature because the examples provided generally cover few edge cases only.
I think I've seen some one create test case tree via comments and the run test for that.
ex: check if following is valid BST, resulting in false
/*
1
/ \
2 3
*/
if you click the 'Console' window on leetcode, it allows you to pass custom test cases
sir, please make a solution video on Next Permutation problem . Leetcode 31
Tbh that question chases me in my dreams XD
sure, I will add it to my pipeline of videos.
Is there anyone facing issue imagining how recursion works?
could you dry run this question
I will do a video on dry running a recursive problem.
This is one of the hurdles that make a huge difference in your ability to solve problems. Take some time to focus on recursion. Look at various simpler recursive problems until you can start to see patterns and visualize how it works. Once you can visualize recursion it will be a quantum leap forward in your programming skills. There are a lot of milestones like this, just try not to get discouraged and keep finding material on the subject until it clicks. You'll eventually have enough practice or find the perfect lesson for you that will make it 'click'.