Explaining Leetcode -

Опубликовано: 26 Февраль 2026
на канале: JTECH
73
1

In this video I explain the algorithm behind solving Leetcode problem 2126 Destroying Asteroids. I first solve the problem using sorting resulting in a time complexity of O(nlogn). Since Java is said to use Merge sort, the space complexity is then O(n). The result is an algorithm that beats 99.3% in time and 92.3% in space

00:00 Introduction + understanding the problem
02:57 Explaining my solution
04:55 Implementing solution

PS: The thumbnail image is on this link https://pixabay.com/illustrations/spa...