Arrays Important Questions
Important Concepts :
- Sorting (Merge sort and quick sort algorithms should be on your tips)
- upper_bound and lower_bound functions
- Sliding window/two pointers a lot of questions are based on this.
- Intervals related problems (asked frequently)
- Know calculation of time complexity and space complexity.
- Hashing (you might not need a map everytime (for C++) you can use an array too)
Easy/Medium (MUST DO)
- https://www.interviewbit.com/problems/add-one-to-number/
- https://www.interviewbit.com/problems/max-sum-contiguous-subarray (IMPORTANT multiple questions are based on this)
- https://www.interviewbit.com/problems/hotel-bookings-possible/
- https://www.interviewbit.com/problems/maximum-unsorted-subarray/
- https://www.interviewbit.com/problems/max-distance/
- https://www.interviewbit.com/problems/merge-intervals/ (IMPORTANT Try doing it in O(n))
- https://www.interviewbit.com/problems/repeat-and-missing-number-array/
- https://www.interviewbit.com/problems/first-missing-integer/
- https://www.interviewbit.com/problems/next-permutation/
- https://www.interviewbit.com/problems/intersection-of-sorted-arrays/
- https://www.interviewbit.com/problems/3-sum/
- https://www.interviewbit.com/problems/remove-duplicates-from-sorted-array/
- https://www.interviewbit.com/problems/trailing-zeros-in-factorial/
- https://www.interviewbit.com/problems/grid-unique-paths/ (Can use DP as well but there is a combinatorics solution which is simpler and has a better time complexity)
Hard
- https://www.interviewbit.com/problems/n3-repeat-number/ (can avoid)
- https://www.interviewbit.com/problems/container-with-most-water/ (IMPORTANT)
- https://practice.geeksforgeeks.org/problems/inversion-of-array/0/
- https://practice.geeksforgeeks.org/problems/largest-number-formed-from-an-array/0
- https://leetcode.com/problems/subarray-sum-equals-k/ (IMPORTANT asked frequently)