Great article! Completely agree with your points. One question- sometimes identifying the pattern can be difficult because one problem can have many patterns, and sometimes problems are tricky, so how do you get around that?
Love your work and hope to see more from you soon :)
As an example a lot of the subarray problems with prefix sum based solution also seem like a sliding window type problem. Any tips on differentiating those?
Great Stuff for revision, Can you Please Add more on DP section and Graph section .
sure, will do.
Awesome for quick refresh
precious content
Thanks for sharing this valuable patterns sir .
awesome ! Have watched your youtube videos too ! Great work
For Prefix sum we need one check as if i=0 then prefix sum is array[j]
agree.. that's an edge case we need to handle. Thanks for pointing it out.
Thanks a lot for sharing the pattern aspect to solve the problems..
you are welcome!
Great article! Completely agree with your points. One question- sometimes identifying the pattern can be difficult because one problem can have many patterns, and sometimes problems are tricky, so how do you get around that?
Love your work and hope to see more from you soon :)
It takes some practice to be able to identify the right pattern for the problem at hand.
For tricky problem, it might be a good idea to brainstorm multiple patterns and see which one fits.
As an example a lot of the subarray problems with prefix sum based solution also seem like a sliding window type problem. Any tips on differentiating those?
So awesome resource for Leetcode, thanks for sharing!
thank you so much!
Well drafted.
thank you!
Can you also add one sample code implementation for the patterns with the best approach. Then it will be all at one place.
Thank you
Thanks for this article.