I try leetcode exercises daily and dump them in this repo for tracking .
# | Title | No | Time | Space | Comments | 🧑🏾💻 |
---|---|---|---|---|---|---|
1 | Merge Array | 88 | O(m+n) | O(1) | ||
2 | Remove Element | 27 | O(n) | O(1) | ||
3 | Rotate Array | 189 | O(n) | O(1) | ||
4 | Reverse Words In a String | 151 | O(n) | O(n) | ||
5 | Is Subsequence | 392 | O(n) | O(1) | ||
6 | Minimum Size Subarray Sum | 209 | O(n) | O(1) | Sliding Window | |
7 | Group Anagram | 49 | O(nm) | O(om) | dictionary | |
8 | Search in Rotated Sorted Array | 33 | O(nm) | O(om) | dictionary | |
9 | Find First and Last Position in a Sorted Array | 34 | O(logn) | O(1) | Binary Search | |
10 | Valid Paranthese | 20 | O(n) | O(n) | Stack | |
11 | Min Stack Implmentation | 155 | O(1) | O(n) | Stack | |
12 | Best Time to Buy and Sell Stocks 1 | 121 | O(1) | O(n) | two Pointers | |
13 | Best Time to Buy and Sell Stocks 2 | 122 | O(1) | O(n) | two Pointers | |
14 | Simplify Path | 71 | O(n) | O(n) | stacks | |
15 | Link List Cycle | 141 | O(n) | O(n) | link list |