HR Issues

Is there a compilation of patterns / techniques somewhere ?

Undisclosed $$??
Nov 28

There are hundreds upon hundreds of questions on Leetcode and I wanted to see if there’s a source where I can learn the most common patterns ( sliding window , bfs , dfs etc) instead of trying to do 400 questions

comments

Add a comment
  • Google ∞ + 1
    Just about any fundamentals of computer science textbook.

    I'm not trying to be snarky. I'll give you the benefit of the doubt and assume you're not a cs/softeng grad that copied all their homework from their friends, and are a non-tech type trying to change career paths.

    Things like bfs/dfs are basic algorithms that any textbook will cover, along with all the other basic theoretical stuff you need to practice in problems.

    Things like "sliding window" aren't really covered in most books, because it's just "looking through an array"... When people say "we can do this with a sliding window", it's not because there's a cs technique called "sliding window" that is taught in school. You're just solving a problem with a loop or two. Terminology like "sliding window" and "inchworm" just emerge naturally when discussing it. I guess that's similar to "patterns" but... Just do problems and you'll see the patterns. Trying to memorize them is an awful idea. You should know them from experience.

    If you're just learning to program and trying to apply specific techniques to problems, I highly recommend HackerRank. You can go by topic, and solve increasingly difficult problems within an area.
    Nov 282
  • Microsoft LiftMore
    Your best chance of performing well is discovering those patterns yourself through the completion of problems. That's the only way you'll be prepared systematically for any question that could arise. Otherwise you're just playing long odds that the pattern you've memorized is applicable to any problem at hand
    Nov 285
    • New atmm
      That's very inefficient. Has nobody wrote a book and guide on the top N most common patterns/tricks you can use to solve leetcode question. I'm sure OP was looking for a 80/20 solution and many of us would like that too.
      Nov 28
    • Intuit t0@y
      The point is to be prepared in a systemic way instead of memorizing existing solutions. Even if it looks a problem falls into a known category so you can apply a corresponding pattern, problems are unique, solutions should be provided adequate to the problems. There are tons of moments when an existing pattern needs to be modified to achieve the right solution. So without general Education in CS it is hard to be ready to all interview questions not even mentioning to do the job well if hired.
      Nov 28
    • Microsoft LiftMore
      Most people aren't smart enough that efficiency is the priority. Most people need to maximize the probability of the offer, hence the suggestion. I don't disagree an 80/20 resource would be helpful. Sites like Interview Cake accomplish this
      Nov 28
    • New atmm
      @Intuit it's not about memorizing solutions. It's about a faster way of learning if all common patterns and templates are preidentified.
      Nov 28
    • Intuit t0@y
      @atmm I understand that completely. My point is that without comprehensive CS background all those patterns will not help. In order to learn you need to understand them and then using them will become a natural thought process.
      Nov 28
  • New numaye
    Introduction to algorithms
    Nov 280
  • This comment was deleted by original commenter.

    • Zalando n00bistan
      that’s the only way to hide company name i think 💁‍♂️
      Nov 28
    • Undisclosed $$??
      OP
      Yup don’t wanna get rekt for posting on blind
      Nov 28
  • Undisclosed $$??
    OP
    I’m about 150 leet in and still don’t feel confident to know exactly what to do to learn the tricks and strategies
    Nov 281
    • OP - on solving Leetcode problem, do you always look at the solution too after giving your solution? That's one way to learn about optimized solution and other possible solutions.
      Nov 28
  • Airbnb jim.hodlen
    get a competitive programming textbook and it should be more than sufficient (still helps to practice a few problems though)
    Nov 280

Download the app for more exclusive content.