6473. Maximum Sum Queries | Merge Sort Trees | Segment Tree | Leetcode Weekly Contest 349

Опубликовано: 01 Апрель 2026
на канале: codingMohan
1,940
63

Segment Trees Series - https://bit.ly/segment-trees
Part 1 -    • Segment Trees Series | Basics of Segment T...  
Part 2 -    • Segment Trees Series | Queries on prefix o...  
Part 3 -    • Segment Trees Series | Part 3 | Solving Co...  
Part 4 -    • Segment Trees Series | Part 4 | Solving Co...  
Part 5 -    • Segment Trees Series | Part 5 | Longest In...  
Part 6 -    • Segment Trees Series | Part 6 | Solving Sp...  
Part 7 -    • Segment Trees Series | Part 7 | Binary Sea...  

Segment Trees Problems Playlist -    • Segment Trees  

*************************************************
Contest Link - https://leetcode.com/contest/weekly-c...
Problem Link - https://leetcode.com/contest/weekly-c...

Solution - https://leetcode.com/problems/maximum...

*************************************************
Timestamps -

00:00 - Agenda
01:20 - Problem Description
04:13 - Solving reduced version (without Y constraint)
08:41 - Time Complexity of reduced version
09:54 - Solving complete problem
12:00 - 1st Approach - Merge Sort Tree
15:55 - Time Complexity (1st Approach)
17:30 - 2nd Approach - Sorting queries
18:30 - Intuition to optimize the solution
22:15 - Dry run of the Algorithm
30:13 - Recap of the complete solution
36:14 - Time Complexity (2nd Approach)
38:57 - Pseudo code
44:15 - Code Walkthrough

*************************************************
Interview Experiences Playlists -

Microsoft -    • Microsoft Interview Questions  
Amazon -    • Amazon Interview Questions  
D.E.Shaw -    • D.E.Shaw Interview Questions  
Linkedin -    • Linkedin Interview Questions  
Facebook -    • Facebook (Meta) Interview Questions  
*********************************************************************

Please show support and subscribe if you find the content useful.