Hello, Friends! Today I have solved three problems on LeetCode. Single Number, First Missing Positive, and Next Greater Element III. We all commit a lot of the same mistakes that we are going to cover. Like, when we get an easy problem, we try to skip it or apply the known method and quickly finish it and forget. But then, use resources to see whether the solution you came up with is the most efficient one. If it's not, take time to learn the more efficient solution.
Single Number is an easy problem, and I knew one approach. But I was curious to know what was the most efficient solution. When I got it, I was really surprised to see that the problem can be solved in such an efficient manner.
Similarly, while solving problems First Missing Positive and Next Greater Element III, it is required that the focus should be at creating a good logic basis then break it down this process will make it easier and therefore help in solving problems and, of course, develop better answers.
I hope that my experience is also helpful to you.
Top comments (0)