LeetCode 2104. Sum of Subarray Ranges
24:37
CTCI 4.9 BST Sequences - Java
25:33
2 жыл бұрын
LeetCode 370. Range Addition
10:56
2 жыл бұрын
LeetCode 630. Course Schedule III
4:56
LeetCode 79. Word Search
13:16
2 жыл бұрын
Пікірлер
@sidharthkumar2546
@sidharthkumar2546 16 күн бұрын
EMO !!!
@НинаКамкия
@НинаКамкия 21 күн бұрын
why i can't do something like this: while True: ans = rand7() + rand7() if ans <= 9: return ans + 1
@shaypatrickcormac2765
@shaypatrickcormac2765 24 күн бұрын
give me your time machine
@healedcoffee
@healedcoffee Ай бұрын
this is so helpful! love how you count the total subarrays using the left & right bracket!
@draugno7
@draugno7 Ай бұрын
yeah, I'd totally come up with that on the spot... :')) dp(n^2) solution though, I think so. But I will remember this in case I need it
@nhatnamnguyenminh7926
@nhatnamnguyenminh7926 Ай бұрын
Simple makes PERFECT!
@bluewhale37
@bluewhale37 Ай бұрын
Thank you so much kacy.
@rushio8673
@rushio8673 2 ай бұрын
loved it, one of the easiest and best explanation. Thank you !
@VishnuvarthanM-n2f
@VishnuvarthanM-n2f 3 ай бұрын
tqq for this stuff ^^
@JDogMcSteezy
@JDogMcSteezy 3 ай бұрын
Thank you for the iterative explanation
@JDogMcSteezy
@JDogMcSteezy 3 ай бұрын
Thanks! The editorial did not really explain it and the popular channels stopped at the iterative solution
@Account-fi1cu
@Account-fi1cu 3 ай бұрын
solved it intuitively using max heap,, but this is more efficient.. alas less obvious to wrap my head around it. thankyou !
@amadhurip9946
@amadhurip9946 3 ай бұрын
this guy is so cool
@KacyCodes
@KacyCodes 2 ай бұрын
@@amadhurip9946 😎
@tomreyker9329
@tomreyker9329 3 ай бұрын
The proves were real nice. I was struggling with it. Thanks.
@web-unlocked
@web-unlocked 3 ай бұрын
Love you solution (and your voice)
@ZachDift-kc4nk
@ZachDift-kc4nk 4 ай бұрын
I got this question for amazon's OA and also a question similar to this for IBM's OA on the coding portion so this is a good question to review. Too bad i didnt know how to do it 😭
@kasthurirangan3455
@kasthurirangan3455 4 ай бұрын
instead of adding only odd length why are u adding all ?
@aammarahmad
@aammarahmad 4 ай бұрын
epic vid! thx!
@shahidullahmuffakir668
@shahidullahmuffakir668 4 ай бұрын
Good job brother, you explained the whole algo withing the first 4th minute. thank you. keep it up.
@mayankbhanot8986
@mayankbhanot8986 4 ай бұрын
omg, the prefix sum explanation was so good
@jaideepdahiya4057
@jaideepdahiya4057 5 ай бұрын
good explanation
@torr-o8v
@torr-o8v 5 ай бұрын
is it really hard to grasp or I'm dumb?
@21centuryschizoid
@21centuryschizoid 5 ай бұрын
I missed why this algorithm is nlogn
@NimishJindal-e6m
@NimishJindal-e6m 4 ай бұрын
I was also initially confused. But this is my understanding: Searching for an element in the pile is logn (binary search). We do this for every element in the array (n). So total complexity is nlogn
@santiagoramirez851
@santiagoramirez851 5 ай бұрын
Awesome!
@raghvendrakumarrai7183
@raghvendrakumarrai7183 5 ай бұрын
Great Explanation! Thank you for such a beautiful explanation!😊😊
@ndot8499
@ndot8499 6 ай бұрын
Bro u R me Fr
@oliverlooker
@oliverlooker 6 ай бұрын
I put this exact code into my IntelliJ IDE and it doesn't work. The power function doesn't work. Any ideas? I am trying to write an asymmetric encryption program and need to figure this out.
@fredyrocky
@fredyrocky 6 ай бұрын
How about using two pointers. The first pointer starts from the beginning of each range and increases by 1 until it finds the first pipe and is less than end of range. The second pointer if (left pointer +1) and increases by 1 until it finds a pipe. We add the difference between both the pointers -1 as the current count of the stars. Then, we make the first pointer to start from the second pointer. And the secondpointer starts from firstpointer +1. We always check if the pointers are less than right.
@sahilamin219
@sahilamin219 7 ай бұрын
i like your hair, do not you get dandruff !!
@KacyCodes
@KacyCodes 7 ай бұрын
Never cause I use anti-dandruff shampoo twice a week 😎
@sourabhsingh4449
@sourabhsingh4449 7 ай бұрын
Thanks man, it was very helpful and so much to learn form this video more than what was needed to solve question. Keep up the good work of spreading knowledge
@IAmIndraTheGod
@IAmIndraTheGod 8 ай бұрын
Nice explanation and solution. appreciate your work.
@homeroserna9983
@homeroserna9983 8 ай бұрын
Good solution. I like that you did it with regular arrays makes it easy to transfer the logic to other languages.
@edwinrosemond989
@edwinrosemond989 8 ай бұрын
Incredible video! really good explanation thanks so much
@ithsigma
@ithsigma 9 ай бұрын
Very clever explanation. Thank you so much!
@anupamchopra5753
@anupamchopra5753 9 ай бұрын
Thank you brother beautiful explanation
@aaditya_87
@aaditya_87 9 ай бұрын
awesome!
@codeman0017
@codeman0017 9 ай бұрын
damn bro great explanation please continue doing vedioes
@glidermcglide9288
@glidermcglide9288 9 ай бұрын
This guy gives off the vibes of a HERO !
@shriramravichandran2956
@shriramravichandran2956 10 ай бұрын
Hey Kacy the explanation was so good. Can you teach monotonic queues as well?
@jui20oct
@jui20oct 10 ай бұрын
Out of all the vides on youtube, I understood your explanation! Thank you!
@axlrose5082
@axlrose5082 10 ай бұрын
You know it's a great explanation when you can code and submit the solution for yourself without even reading a single line of code from the instructor lol. Thank you!
@sandeshsinha9174
@sandeshsinha9174 10 ай бұрын
You won’t remember the solution today. That day was a short term memory I think. 😬😬
@johnapple3471
@johnapple3471 10 ай бұрын
2007 vibes
@Rahul-pr1zr
@Rahul-pr1zr 10 ай бұрын
How did you come up with the idea of choosing the bottom left or top right for calculating the no. of elements <= mid?
@vydruth
@vydruth 10 ай бұрын
Thanks for the clear explanation! Very helpful! 👍
@hangchen
@hangchen 10 ай бұрын
Code Ninja
@tod3117
@tod3117 11 ай бұрын
THANK YOU!!!!!!!
@alanchen6872
@alanchen6872 11 ай бұрын
It is very useful. Thanks mate.
@haqinzmamul12
@haqinzmamul12 11 ай бұрын
Great Kacy...
@potodds_trading
@potodds_trading 11 ай бұрын
Great explanation in Java code. Better than some of the Python solution as they use built-in functions that let you "see" the solution as clearly.
@pravinthganesan8552
@pravinthganesan8552 11 ай бұрын
Thanks for the explanation, able to understand the logic behind the solution for range addition and related problems, Thanks.