LeetCode #48: Rotate Image
https://leetcode.com/problems/rotate-image/ To rotate a matrix in-place by 90 degrees, we will use a nested loop to iterate over each of…
https://leetcode.com/problems/rotate-image/ To rotate a matrix in-place by 90 degrees, we will use a nested loop to iterate over each of…
https://leetcode.com/problems/meeting-rooms-ii/ To solve this problem, we will use a heap and a greedy approach. We will keep track of the…
https://leetcode.com/problems/meeting-rooms/description/ In this problem, we are given a list of intervals, each representing a meeting start and end time, and…
https://leetcode.com/problems/non-overlapping-intervals/description/ Given a collection of intervals, find the minimum number of intervals you need to remove to make the rest…
https://leetcode.com/problems/merge-intervals/description/ In this problem, we have to merge overlapping intervals in a list. We are given a list of intervals…
https://leetcode.com/problems/insert-interval/description/ To solve this problem, we can iterate over the intervals in the list, and compare them with the new…
https://leetcode.com/problems/jump-game/ We can solve this problem using a greedy approach. We can keep track of the furthest index that can…
https://leetcode.com/problems/maximum-subarray/ The problem requires finding the maximum sum of a contiguous subarray. This problem can be solved using the Kadane’s…
https://leetcode.com/problems/longest-common-subsequence/description/ A subsequence is a sequence that can be derived from another sequence by deleting some or no elements without…
https://leetcode.com/problems/unique-paths/description/ To solve this problem, we can use dynamic programming. We create a 2D array path where path[i][j] represents the…