Top Company Interview Preparation

Arrays And Strings

1. 3 Sum - Find all triplets with sum Zero

2. Two Sum

3. Plus One - Adding one to number represented as an array of digits

5. Move Zeros

6. Jump Game

7. Spiral Matrix

8. Rotate Image - Rotate a (N x N) 2D matrix by 90 degree

9. Reverse String

10. Missing Ranges

11. Multiply Strings

12. Set Matrix Zeros

13. Missing Number

14. Group Anagrams

15. Integer to Roman

16. Expressive Words

17. Roman to Integer

18. Valid Palindrome

19. Next Permutation

20. Meeting Rooms II

21. Valid Parentheses

22. Reorder Log Files

23. Most Common Words

24. One Edit Distance

25. Next Closest Time

26. Implement strStr()

27. Merge Sorted Array

29. Valid Palindrome II

30. Trapping Rain Water

31. Merge k Sorted Lists

32. Subarray Sum Equals K

33. Compare Version Numbers

34. Backspace String Compare

35. Integer to English Words

36. Minimum Window Substring

37. String to Integer (atoi)

38. Container With Most Water

39. Reverse Words in a String

40. Find And Replace in String

41. K Closest Points to Origin

42. Product of Array Except Self

43. Reverse Words in a String II

44. Longest Palindromic Substring

46. Minimum Cost to Hire K Workers

47. Kth Largest Element in an Array

48. First Unique Character in a String

49. Maximize Distance to Closest Person

50. Remove Duplicates from Sorted Array

51. Longest Substring Without Repeating Characters

52. Longest Substring with At Most K Distinct Characters

54. Longest Substring with At Most Two Distinct Characters

55. Find first missing positive number in an array of Integers

56. Strobogrammatic Number

1. Reorder List

5. Merge Two Sorted Lists

6. Reverse Nodes in k-Group

7. Copy List with Random Pointer

8. Remove Nth Node From End of List

9. The intersection of Two Linked Lists

Tree & Graph

1. Flood Fill

2. Word Search

3. Clone Graph

5. Course Schedule

6. Alien Dictionary

7. Cracking the Safe

8. Number of Islands

9. Course Schedule II

10. Robot Room Cleaner

11. Is Graph Bipartite?

12. The diameter of the Binary Tree

13. Count Complete Tree Nodes

14. Validate Binary Search Tree

15. Binary Tree Right Side View

16. Flip Equivalent Binary Trees

17. Cut Off Trees for Golf Event

18. Binary Tree Maximum Path Sum

19. Serialize and Deserialize BST

20. Decode String  Evaluate Division

21. Flatten Binary Tree to Linked List

22. Longest Increasing Path in a Matrix

23. Shortest Distance from All Buildings

24. Binary Tree Vertical Order Traversal

25. Count of smaller numbers after self

26. Serialize and Deserialize Binary Tree

27. Lowest Common Ancestor of a Binary Tree

28. Binary Tree Zigzag Level Order Traversal

29. Most Stones Removed with Same Row or Column

30. Construct Binary Tree from Preorder and Inorder Traversal

31. Convert Binary Search Tree to Sorted Doubly Linked List

32. Count nodes of a Binary Search Tree within a given range

33. Sum of Binary Search Tree Within Given range

34. Delete nodes from Binary Tree and return a forest.

35. Evaluate Division

36. Find duplicate subtrees

37. Reconstruct Itinerary

38. Maximum increasing path in a matrix

39. Most stones removed from same row or column

Sorting and Searching

1. Pow(x, n)

2. Merge Intervals

3. Meeting Rooms II

4. Find Peak Element

6. Divide Two Integers

7. Top K Frequent Elements

8. Validate a Mountain Array

9. The intersection of Two Arrays

10. Median of Two Sorted Arrays

11. The intersection of Two Arrays II

12. Peak Index in a Mountain Array

13. Search in Rotated Sorted Array

14. Kth Largest Element in an Array

15. Two Sum II - Input array is sorted

16. Find First And Last Position of Element in Sorted Array

1. Maximum subarray sum

2. Maximum product subarray

3. Split Array Largest Sum

4. Longest Palindromic substring

5. Best time to buy and sell stock

6. Coin Change

7. Regular Expression Matching

8. Wildcard Matching

9. Unique Paths

10. Minimum Path Sum

11. Edit Distance

12. Climbing Stairs

13. Maximal Rectangle

14. Unique Binary Search Trees II

15. Unique Binary Search Trees

16. Interleaving String

17. Distinct Subsequences

18. Word Break

19. Range Sum Query - Immutable

20. Android Unlock Patterns

21. Maximal Rectangle

22. House Robber

23. Counting Bits

24. Burst Balloons

25. Count numbers with unique digits

26. Scramble String

27. Cherry Pickup

28. Frog Jump

29. Super Egg Drop

30. Tallest Billboard

Design

1. LRU Cache

2. Min Stack

3. Insert Delete and Get Random in O(1)

4. Logger Rate Limiter

5. Maximum Frequency Stack

6. Design Tic-Tac-Toe

7. Find median from the data stream

8. Find the average of the data stream

9. Design Search auto-complete system

10. Implement Trie

11. The Skyline Problem

12. Binary Search Tree iterator

13. Design Snake Game

14. Design Hit Counter

15. Encode and decode tiny url

Others

1. Remove duplicate from sorted array

2. Find minimum in a rotated sorted array

3. Search a 2D matrix

4. Sort colors

5. Merge Sorted array

6. Check if a number is palindrome or not

7. Reverse a 32 bit signed integer

8. Letter combination of phone numbers

10. Serialize and Deserialize N-Ary Tree

11. Bulls and Cows

12. My Calendar

13. Swap adjacent in LR string

14. Guess the word

15. Distribute candy on weight

16. Jewels and Stones

17. Time-Based Key-Value Store

18. Minimum Swaps To Make Sequences Increasing

19. Encode and Decode Strings

20. Minimum Window Subsequence

21. Network Delay Time

22. Split Array into Consecutive Subsequences

23. String Transforms Into Another String

24. Confusing Number II

25. Path with Maximum Gold

Algorithm