Programming/Coding Test

코딩 인터뷰에 등장하는 Top 6 개념

빠모스 2023. 7. 8. 21:27
반응형

Top 6 Coding Interview Concepts (Data Structures & Algorithms)

 

Number 6 : Heaps

- two variation : minimum heap, maximum heap

- Find minimum, maximum value or top k value 문제들에서 많이 사용

Number 5 : Sliding Window

- iterative through array n time

- type of algorithm that you can memorize and apply to many different problems

- keep track of two points, don't have to use nested loop

 

Number 4 : Binary Search

- Guess number higher or lower

- O(logn)

 

Number 3 : DFS & BFS

- Very common algorithm

- Most graph algorithm build on DFS & BFS

- You can solve very large number of problems with this

- Also with trees

- Once you write them so many times, it becomes like second nature. Very standard.

- Time & Space complexity

- usually O(V+E)

 

Number 2 : Recursion

- Is applied in so many places

- Also used in graph, back tracking, DP... 

- 다른 recursion을 이용한 알고리즘들이 어려운건 recursion을 제대로 이해하지 못하고 있기 때문

 

Number 1 : HashMaps

- Two Sum이 HashMap을 이용한 가장 대표적인 문제

- HashMap만 사용해도 풀수있는 문제가 참 많음

- HashMap is always used as utility data structure to do things efficiently

 

반응형