Most of the classic interview questions have multiple solution approaches. For the best practice result, we strongly advise you to go through this list at least a second time, or even better - a third time. By the second attempt, you may discover some new tricks or new methods. By the third time, you should find that your code appear to be more concise compared to your first attempt. If so, congratulations!
Array type of questions were asked in interviews frequently. You will most likely encounter one during your interviews.
We recommend: Single Number, Rotate Array, Intersection of Two Arrays II and Two Sum.
S.No | Title | Solution | Time | Space | Difficulty |
---|---|---|---|---|---|
1619 | Mean of Array After Removing Some Elements | JavaScript | O(n) | O(1) | Easy |
27 | Remove Element | JavaScript | O(n) | O(1) | Easy |
1394 | Find Lucky Integer in an Array | JavaScript | O(n) | O(1) | Easy |
191 | Number of 1 Bits | JavaScript | O(1) | O(1) | Easy |
1365 | How Many Numbers Are Smaller Than the Current Number | JavaScript | O(n) | O(1) | Easy |
26 | Remove Duplicates from Sorted Array | JavaScript | O(n) | O(1) | Easy |