Merge Sort | Algorithm | Pseudocode | Dry Run | Code | Strivers A2Z DSA Course

  Рет қаралды 549,607

take U forward

take U forward

Күн бұрын

Пікірлер: 1 000
@takeUforward
@takeUforward Жыл бұрын
Let's march ahead, and create an unmatchable DSA course! ❤ Can someone please add timestamps, I will add them post-it.
@msdarshankirthic9990
@msdarshankirthic9990 Жыл бұрын
time stamps done bro
@harshavardhan184
@harshavardhan184 Жыл бұрын
Bhai please upload videos asap..😭we from a normal tier 3 college are hoping for your videos...pls don't late
@harshavardhan184
@harshavardhan184 Жыл бұрын
#striver pls make videos faster bhai 😭
@harshavardhan184
@harshavardhan184 Жыл бұрын
#striver pls make videos faster bhai 😭..your content is too gud ...but our placements are going on fastly
@Shubham-bh1ph
@Shubham-bh1ph Жыл бұрын
Bhaiya please be fast in terms of uploading videos 😭😭😭
@Akash-xr6we
@Akash-xr6we Жыл бұрын
inspiration recording at 3 am when he can create content with so much dedication then why can't we learn dsa with same dedication hats off to you man.💯💯
@random-xl3zm
@random-xl3zm 8 ай бұрын
190 + likes to this comment but no sub comments Lemme fix it
@random-xl3zm
@random-xl3zm 8 ай бұрын
Hare krishna
@random-xl3zm
@random-xl3zm 8 ай бұрын
Hare krishna hare krishna krishna krishna hare hare Hare rama hare rama rama rama hare hare Chant this and be happy
@Akash-xr6we
@Akash-xr6we 8 ай бұрын
@@random-xl3zm 😂😂 thanks dude
@random-xl3zm
@random-xl3zm 8 ай бұрын
@@Akash-xr6we no worries Jai siya ram😁
@raodevendrasingh
@raodevendrasingh Жыл бұрын
just woke up and started doing dsa, and you are recording it at midnight, your efforts are not wasted at all Sir!! Thank you for providing such quality content for free.
@hiteshpanchal5772
@hiteshpanchal5772 Жыл бұрын
same brother.............i was watching the video suddenly at last striver said it's 3.30am and i just felt sham on my self boz he is teaching till night and i don't learn genuinely..
@expl0itr
@expl0itr 5 ай бұрын
In 4 years of college, when teachers came to copy and paste from their 10year old notes I couldn't gain any interest in DSA and felt stupid and never touched the topic post exam. And everything instantly clicked when I watched this video. Honestly your course is giving me insane confidence already. Hope I can make a change within a year, though it's difficult after doing full-time job but I get my confidence back when i see you making this huge stuff after working same or more hours. Planning to stay consistent! Thanks a lot! PS: We have the same chair 😁
@dhruvinkalathiya3809
@dhruvinkalathiya3809 5 ай бұрын
But why i can't hear his voice
@msdarshankirthic9990
@msdarshankirthic9990 Жыл бұрын
MERGE SORT - O(nlogn) - divide and conquer 1:16 - What is and Why Merge sort 3:00- Divide 5:54- Merge Pseudo code 17:15 - approach (divide) 20:34 - pseudo code (divide) 25:00 - dry run on divide (pseudo code breakdown) 32:42 - approach (merge) 33:46 - pseudo code (merge) 40:33 - C++ code 44:10 - Time complexity analysis 48:05 - Space complexity analysis ❤
@kaizjessani7303
@kaizjessani7303 Жыл бұрын
In my 4 years of engineering and 7 years of work experience, I finally understood merge sort with recursion. I can finally move ahead and sleep properly😂 Thank you so much. Really appreciated 🙏🙏🙏 Love you bro ❤
@Vishalkumar-fe9fu
@Vishalkumar-fe9fu Жыл бұрын
🤣
@iamnoob7593
@iamnoob7593 9 ай бұрын
now the question is whether u r going use it or not
@kaizjessani7303
@kaizjessani7303 9 ай бұрын
@@iamnoob7593 😂😂
@vivekgautam9766
@vivekgautam9766 24 күн бұрын
@@iamnoob7593 🤣🤣🤣🤣🤣🤣
@saivarun5529
@saivarun5529 Жыл бұрын
Superb explanation, sat for around 4hrs to understand how merge sort is working and then I found this video. Understood clearly within 50mins. Very nice and deep explanation.
@darshanakv4946
@darshanakv4946 5 ай бұрын
The title "STRIVER" for a reason!!✅
@ishaanrawal9327
@ishaanrawal9327 Жыл бұрын
It's 3:34 in the AM right now and I'm absolutely loving your videos and implementing them simultaneously! I can't ever thank you enough for the amazing content that you've put out! I have my placement drive starting in approximately 100 days and plan to make the most out of it with the help of your lessons! Dil se thank you bhai! Will update my placement status soon!
@glazefrect1337
@glazefrect1337 Жыл бұрын
So, What's the status bro?
@discarded1669
@discarded1669 Жыл бұрын
where are u working now?
@adndrewjoseph5572
@adndrewjoseph5572 10 ай бұрын
bro placed?
@deveshmanitripathi9419
@deveshmanitripathi9419 Жыл бұрын
Striver teaching how to code is just like a story. It really seems so easy to understand 😊
@changed217
@changed217 Жыл бұрын
The efforts taken to make this video must have been insane, because this was frankly explained so well it's honestly brilliant. Thank you for all your efforts. Completing this at 4:47am here.
@iamnoob7593
@iamnoob7593 9 ай бұрын
No compromise on sleep from my side , Body does not listen to emotions
@amitpatil6244
@amitpatil6244 Жыл бұрын
This is called content 🤓✨
@Pooja-we3xs
@Pooja-we3xs Жыл бұрын
Before I use to feel merge sort very difficult but after watching this video, I understood it very clearly. Thank you Striver.
@prathamesh_utube
@prathamesh_utube Жыл бұрын
Thanks Striver, I 'understood' it perfectly! This channel has the potential to become huge with content like this.
@devanshusangra6294
@devanshusangra6294 Жыл бұрын
44:2 - "I write codes in one go", the confidence i want
@payaljain6825
@payaljain6825 Жыл бұрын
This level of clarity would have never been possible without ur video. Your energy of teaching any topic is what makes it more interesting. 🤟
@AmanKumar-fe2ez
@AmanKumar-fe2ez Жыл бұрын
Best merge sort ever but i little bit mad so have to watch it 2-3 times to get properly in my head btw thankyou Striver
@ksankethkumar7223
@ksankethkumar7223 Жыл бұрын
int mid =(low + high) / 2; might give an integer over flow resulting in a negative index which would throw Array out of Bounds Exception and hence its a good practice to use int mid = low + ((high - low) / 2); or faster way is int mid = (low + high) >>> 1 (For Java) and int mid = ((unsigned int)low + (unsigned int)high)) >> 1 (For CPP) to avoid any kind of overflows..
@utkarshsingh5652
@utkarshsingh5652 11 ай бұрын
why in the last we did arr[i] = temp[i-low] and not arr[i]=temp[i ]
@ksankethkumar7223
@ksankethkumar7223 11 ай бұрын
@@utkarshsingh5652 Because every time the low is not zero. In deeper recursive calls, low can be anything
@shivangitekriwal3056
@shivangitekriwal3056 4 ай бұрын
​@@ksankethkumar7223but we added elements in temp so index might be from 0 to high??
@NihalNamdeo
@NihalNamdeo Ай бұрын
​@@utkarshsingh5652 bro did u understand i-low concept?
@NihalNamdeo
@NihalNamdeo Ай бұрын
can you explain i-low logic please, I can't get that? low would always be 0, I don't understand the point, although not doing this, does give an error
@yhbarve
@yhbarve Жыл бұрын
This was the best explanation for Merge Sort on KZbin! Thanks
@Shagunverma-l8l
@Shagunverma-l8l 6 ай бұрын
Fr
@MANISHKUMAR-vn1yh
@MANISHKUMAR-vn1yh Жыл бұрын
best merge sort explanation on KZbin ever I'll never forget that thanks bhaiyya!
@pcyvlogs8130
@pcyvlogs8130 9 ай бұрын
From all the KZbin tutorials, I definitely think that your videos are the best in terms of explanation and easy understanding. Thanks a lot, and please keep it up, I love the content!!!!!
@nandanitiwari8098
@nandanitiwari8098 9 ай бұрын
These is the best explanation I have find in my entire dsa life. The best part that I always found in other dsa lectures is the best dry run and how to convert that explanation in code. ALOT OF THANKS. And that Time and Space Complexity part is like "Add a feather in a cap"
@subhamsharma9097
@subhamsharma9097 Жыл бұрын
You are the real hero .. providing such a beautiful content in free of cost. thanks a lot bro.
@ritikumaroy
@ritikumaroy Жыл бұрын
A little correction at 24:37 You can't write if(low>=high). It will cross the time limit in some cases. As I'm facing this issue in GFG merge sort problem. Instead use if(low==high)
@venkatgaddam6587
@venkatgaddam6587 Жыл бұрын
Ohhh!!! nice
@shriyamverma7833
@shriyamverma7833 4 ай бұрын
Thanks for pointing this out, I was getting TLE due to this on Leetcode.
@GOVIND_DWIVEDI
@GOVIND_DWIVEDI 3 ай бұрын
but why it is giving TLE ?
@navneetuppal9753
@navneetuppal9753 Жыл бұрын
As expected, Striver's Top notch explanation made Merge sort crystal clear. UNDERSTOOD!! thankyou striver for all the content
@mdfaizanmdfaizan6041
@mdfaizanmdfaizan6041 3 ай бұрын
Great explanation sir, i didn't understand this concept from love babbar sir so i came here and got it ❤❤❤
@cinime
@cinime Жыл бұрын
Understood! Super amazing explanation as always!! Thank you for your great effort even in the midnight !!!
@rushidesai2836
@rushidesai2836 19 күн бұрын
More than 500k views for this video. Imagine the impact this guy is making in the DSA community.
@varuntanwar6746
@varuntanwar6746 Жыл бұрын
I hope you realize how much value you are creating. It's much more than you think. Thanks a lot!!
@mayankyadav1290
@mayankyadav1290 10 ай бұрын
I'm pausing the video in between just to appreciate you, the way you explain things is just awesome man. Keep the good work coming. God bless you.
@vardhamanbhandari5644
@vardhamanbhandari5644 Жыл бұрын
Understood!! Best Explanation ever🙌🙌🙌🙌 #Striver Aka
@ashishsahay1901
@ashishsahay1901 Жыл бұрын
@Raj you are changing the field of programming even the concepts and the visualization which are difficult for the experienced professional by watching your videos feel like it's just a cakewalk. Thanks for the content, keep doing it. JAVA CODE for the merge Sort Algorithm----- TC--O(n*logn) & SC--O(n) import java.util.*; public class Solution { public static void mergeSort(int[] arr, int n) { // Write your code here. ms(arr,0,n-1); } public static void ms(int arr[],int low,int high) { if(low>=high) { return; } int mid = (low+high)/2; ms(arr, low, mid); ms(arr, mid+1, high); merge(arr,low,mid,high); } public static void merge(int arr[],int low,int mid,int high) { int left = low; int right = mid+1; java.util.List temp = new ArrayList(); while(left
@TrendyGamer007
@TrendyGamer007 Жыл бұрын
just mind blowing explanation .
@the.ankit.07
@the.ankit.07 7 күн бұрын
I wrote the code at first attempt after your explanation ..........thank you so much..
@saurabhkumarsingh9550
@saurabhkumarsingh9550 Жыл бұрын
Bhaiya please make videos on oops concepts.... The only thing missing from your placement series 🥲
@learncreative4732
@learncreative4732 Жыл бұрын
Yes sir please
@shubhamagarwal1434
@shubhamagarwal1434 Ай бұрын
#Free Education For All......... # Bhishma Pitamah of DSA...You could have earned in lacs by putting it as paid couses on udamey or any other elaerning portals, but you decided to make it free...it requires a greate sacrifice and a feeling of giving back to community, there might be very few peope in world who does this...."विद्या का दान ही सर्वोत्तम दान होता है" Hats Off to you man, Salute from 10+ yrs exp guy from BLR, India....
@AdityaKumar-be7hx
@AdityaKumar-be7hx Жыл бұрын
understood! When you get to quicksort please try to cover other related application like kth smallest/largest using quickselect and median in unsorted array in linear time
@meeradhumne4685
@meeradhumne4685 2 ай бұрын
Amazing job explaining step by step in very detail i read lots of article and watched other KZbin, but your explanation is owesome!!!, Thank you so much, before merge sort algorithm was very intimidating, but you made it sounds so easy. Thanks a lot again! I am glad I found your channel.
@amishaagarwal4847
@amishaagarwal4847 Жыл бұрын
why did we use temp [ i-low ] while storing the temp values in original array
@RaghavSharma19201
@RaghavSharma19201 Жыл бұрын
same question please answer
@_HarshKumar-hx8cs
@_HarshKumar-hx8cs Жыл бұрын
To make it start from 0 index ,bcz temp is storing from 0 index
@DeepakGupta-rp8ld
@DeepakGupta-rp8ld Жыл бұрын
Bro only ' i ' is also running...
@MAX_RITIK
@MAX_RITIK 16 күн бұрын
just use arr[i]=temp[i]
@nischayagrawalVlogs
@nischayagrawalVlogs Жыл бұрын
Kya explain kiya hai bro !! like wtf pure yt pe itna acha explanation nai mila meko. Hats off to you my man.
@Raj10185
@Raj10185 Жыл бұрын
The Best video avliable for Merge sort on internet . Tysm Striver Understood everything
@RajeshKumar-x7l5y
@RajeshKumar-x7l5y Ай бұрын
Really appreciate your work ❤❤❤ Actually i confused in this topic from last week and now i got it after watching this super lecture on merge sort Dry run is part best for understanding the concept of merge sort and thank you so much ❤️
@yashhokte1020
@yashhokte1020 Жыл бұрын
Implementation code of Merge Sort algorithm in Java : class Solution { public static void merge(int[]nums,int low,int mid,int high){ int left=low,right=mid+1; Listli = new ArrayList(); while(left
@charuprabha9696
@charuprabha9696 4 ай бұрын
nums[i] = li.get(i-low); why are we doing this? nums[i] = li.get(i) will this not wokr?
@BhavanaReddy15
@BhavanaReddy15 2 ай бұрын
Wow didn't know this was a 50 minute video!! Never made me look at the time ❤❤❤ this is the best video on merge sort❤ thank you very much 😄
@Flash-qr5oh
@Flash-qr5oh Жыл бұрын
@39:52 why can we write temp[i] directly instead of i-low when it only depends on the value of i
@rohandhalpe9084
@rohandhalpe9084 Жыл бұрын
same problem bro ,i cant understand it from past 3 days
@rahulbisht7098
@rahulbisht7098 Жыл бұрын
Same question 💀💀
@amansinghal4663
@amansinghal4663 Жыл бұрын
Because this loop will be recursively called for several times and for each time, the value of low will change. If this loop would have ran only 1 time (i.e. if this loop was inside a non-recursive function), then your logic would have worked. But i am also unable to get how he came up with this logic of (i-low). He forgot to tell the intuition behind it.
@NihalNamdeo
@NihalNamdeo Ай бұрын
​@@rohandhalpe9084bro did you understand it now, please help...
@dishas6328
@dishas6328 28 күн бұрын
Thank you so much for the amazing explanation🙏.I understood the algorithm perfectly only because of this video.
@dangerboy_yt7748
@dangerboy_yt7748 6 ай бұрын
Striver audio got muted please check it
@sahitid5570
@sahitid5570 2 ай бұрын
Shocked to see that the time of completing the recording is 3:20 AM.. It shows your unwavering dedication.. hatsoff to you striver!! you are an inspiration. Understood the concept very well!!
@485_rahulkumar7
@485_rahulkumar7 Жыл бұрын
#striver best merge sort video i ever watched. It clears my all doubt points
@ayushiyadav1
@ayushiyadav1 Ай бұрын
11:44 I've studied this algorithm several times, but the clarity I gained from Striver Bhaiya is unmatched. Thank you sincerely, Bhaiya. ❤
@viskumdee
@viskumdee Жыл бұрын
at 43:49 line number 28 why arr[i]=temp[i-low] ; why (i-low)? why cant we write simply i itself ??
@AmitSharma-nv2oj
@AmitSharma-nv2oj Ай бұрын
same doubt
@Vikhyath_Shetty
@Vikhyath_Shetty 3 ай бұрын
The best explanation on merge sort! I had a confusion while backtracking, which has been sorted out now.
@harshavardhan184
@harshavardhan184 Жыл бұрын
Please make the videos faster...sir please please please....very less time is there for our placements.....my humble request sir😭😭😭😭😭🙏🙏🙏🙏🙏🙏🙏🙏🙏
@Vinayreddy_55
@Vinayreddy_55 24 күн бұрын
You don't understand if he makes videos faster. Just watch the video in 2x speed
@swarnabhkashyap5764
@swarnabhkashyap5764 9 ай бұрын
Great lecture. Slightly different implementation of mergeSort in python. def merge(a1,a2): res = [] l,r = 0,0 while(l
@Vladimir.39665
@Vladimir.39665 Жыл бұрын
for(int i = low; i < high; i++) { arr[i] = temp.get(i - low); } while copying the temp array to original array why we are subtracting low from i, can't we directly write i ?
@AmitSharma-nv2oj
@AmitSharma-nv2oj Ай бұрын
did you got the answer?
@siddhantsingh3346
@siddhantsingh3346 14 күн бұрын
The subtraction of low from i is necessary because temp is a smaller array that starts at index 0, whereas arr is the original array that might start at a higher index low. Here’s the breakdown: i is an index in the original array arr, which ranges from low to high - 1. temp.get(i - low) is accessing the corresponding index in the temp array, which starts from 0. If you directly use i without subtracting low, you would try to access elements from temp at an incorrect index, leading to an out-of-bounds error or incorrect copying. this is the answer given by gpt
@AryanPatel-wb5tp
@AryanPatel-wb5tp 8 күн бұрын
great explanation not one other video on KZbin is as in-depth for the actual understanding of how it works
@harshavardhan184
@harshavardhan184 Жыл бұрын
Will you keep next video or not??.. 14days it's been
@ahnafadib8774
@ahnafadib8774 2 ай бұрын
how is bro so good at explaining, smb give this man an award
@abhinaash4602
@abhinaash4602 6 ай бұрын
why use temp[i=low] and not temp[i] .
@prernasharma9722
@prernasharma9722 27 күн бұрын
For example if the divided array is 1,3 with index 3 and 4... after further division we get two array 1 and 3 . Now we have to sort and then merge and then store in temporary array, whose indexing starts from 0 BUT the original arrays index starts from 3 then 4... that is why we do temp[i-low] to make the index 0 for accessing the 0th element of temp...... Hope you understand.
@daaamn6414
@daaamn6414 2 ай бұрын
Bro thank you for all the HARDWORK you've done to make this so easy for us. T_T
@me.rishiii
@me.rishiii Жыл бұрын
Why are we doing 𝗮𝗿𝗿[ 𝗶 ] = 𝘁𝗲𝗺𝗽[ 𝗶 - 𝗹𝗼𝘄 ] Instead of 𝗮𝗿𝗿[ 𝗶 ] = 𝘁𝗲𝗺𝗽[ 𝗶 ]
@friedfire9462
@friedfire9462 Жыл бұрын
if u found explanation please explain
@Bharat_Rider
@Bharat_Rider Жыл бұрын
See 5 4 3 2 1 Here it will broken as 5 4 3 and 2 1 Then 5 4 3 will be broken as 5 4 and 3 Here low will be 0 so there will be no problem we will copy temp element into the vector but for 2 1 the low I'll be 3 and there in temp vector will have elements in 0 and 1 so to copy them we subtract it will low so that we can access the temp elements at starting indexes
@architgupta8840
@architgupta8840 Жыл бұрын
because the starting value of i is "low" and we need to start from zero in temp i.e, temp[0]
@codinglover5251
@codinglover5251 8 ай бұрын
your explanation method is awesome as compare to other . I saw many video in merge sort but I understand only in this video. thank you sir❤❤🔥🔥👍
@harshavardhan184
@harshavardhan184 Жыл бұрын
#striver pls make videos faster bhai 😭
@AshutoshAnand-o5l
@AshutoshAnand-o5l 4 күн бұрын
What an explainaiton.lIterally Hats off striver..KEEP CREATING KEEP MOTIVATING
@harshavardhan184
@harshavardhan184 Жыл бұрын
Omg 16days per 1video..omg 😱😳 bro..pls think of us..we here are waiting for your videos faster and eager #striver..i think you are consistent 😓😓😓
@hitensamalia
@hitensamalia 9 ай бұрын
kuch kuch aata tha lekin video dekh ke accha se ho gya sab clear... Thanks, bhaiya!!!😊
@ShubhamSharma-zq2xn
@ShubhamSharma-zq2xn 5 ай бұрын
Raj bhaiya, you are literally phenomenal. In this era of recession, you're the sun of hope. So no more excuses just strive every single day to become better.
@viploveparsai9881
@viploveparsai9881 21 күн бұрын
Hats off to you man, great explanation. I didnt get this type of explanation for this algorithm all over th youtube, specially the dry run.
@janatalari6139
@janatalari6139 2 ай бұрын
Before starting this dsa course ,i felt merge sort is very difficult but striver explained it very clearly ..Thank you Striver 😍
@simran5048
@simran5048 Жыл бұрын
Thankyou for explaining this very tough algo in a very simple way , now it's just get locked in my mind , all credit goes to you !! Thanks a lot !
@ArunKumar-vd8zt
@ArunKumar-vd8zt 5 ай бұрын
One of the best explanations I have ever seen on KZbin 🛐
@dumbstonks
@dumbstonks Ай бұрын
Probably the best video available on Merge Sort Ever. Goated.
@nagarajmnaiknagaraj1813
@nagarajmnaiknagaraj1813 4 ай бұрын
How i express your teaching skills You r amazing!!! I seen so many videos on merge sort but no one explain like you even my college professor I thank to myself for finding this amazing playlist.
@RohithVenkatMutyala
@RohithVenkatMutyala 7 күн бұрын
06:13 Merge sort is an optimized sorting algorithm. 12:26 Merge Sort is about merging and sorting arrays in a hypothetical manner 18:39 Merge Sort is an algorithm that divides an array into two halves, sorts them, and then merges them. 24:52 Merge Sort Algorithm using Recursion 31:05 Understanding merge sort through pseudocode and dry run 37:18 Explaining the merge sort algorithm 43:31 Merging left and right arrays 49:43 Merge Sort has a time complexity of n*log(n) and a space complexity of n.
@bharathsampath8171
@bharathsampath8171 Ай бұрын
those who dint understand why we use i-low the reason is that low is given by user so it should not necessarily be 0 so for example if low is 2 and high is 6 so temp will have elements from 2 to 6 in sorted order so arr[low] should be temp[0] and arr[low+1] should be temp[1] and so on.so to map these we use i-low
@thefourhourtalk
@thefourhourtalk 4 ай бұрын
it took me near about 4 hours to completely understand the sorting technique I am in first year of engineering an average guy hoping that ..... this stuff takes time for beginners
@SR09947
@SR09947 Жыл бұрын
Waah bhai thank you i watched a lot of videos of mergesort but no one had explained like u bro❤
@vartikamishra2578
@vartikamishra2578 2 ай бұрын
very nice explanation of recursion sir , thankyou soo much sir
@tahuraalam7
@tahuraalam7 2 ай бұрын
I haven’t seen anyone making such in depth videos 😮. You are doing a great job striver ❤
@premsoni619
@premsoni619 Жыл бұрын
Wow, this DSA course is absolutely fantastic! 🚀 The explanations are clear and easy to follow, and the examples provided really helped solidify my understanding. I've been searching for a comprehensive resource like this, and I'm so glad I stumbled upon it. A huge shoutout to the creator for putting together such a valuable learning resource. Kudos! 👏💯 #DSA #TUF
@Entertainment-fl6ep
@Entertainment-fl6ep 2 ай бұрын
I am just looking for this type of explanation but no one describes like you. At last you described it in part by part thanks a lot brother. I am a big fa of yours ❤❤
@shwetachoudhary9003
@shwetachoudhary9003 2 ай бұрын
u just taugh this algorithm in the most convenient pattern.. i m just too impressed from ur teaching skill sir... thank you soo much❤ Gol bless u
@AshwinCodes
@AshwinCodes Жыл бұрын
I tried understanding merge sort from love babbar and Apna college. But strivers dry run made me understand it clearly.
@Sarjais_Raja
@Sarjais_Raja 3 ай бұрын
The amount of energy and effort you put in this is amazing
@anjalichauragade1486
@anjalichauragade1486 Ай бұрын
I was not understanding that recursive calls....searched a lot for it but no one explained the way you do...tysm😊
@mukundmohan4301
@mukundmohan4301 Ай бұрын
TBH This is my first comment on any study youtube channel ..and i genuinely appreciate this man's effort from bottom of my heart ..whatttaaa explanation ..straight into the head..thankss striver bhaiya 💌💌
@sunitakukreja6700
@sunitakukreja6700 Ай бұрын
Best video, clears all the concept😊😊
@FireGamerz-of6vv
@FireGamerz-of6vv 7 ай бұрын
After Watching Recursion Videos. In sorting once concept is know, i am able to write the structure with code on my own. MAy Be paper work is playing the major role. Every video is full of content with zero to hero. Its really great🚀🚀🚀🚀🚀
@kshitijsrivastava7849
@kshitijsrivastava7849 Жыл бұрын
watching ur for first time and my mind blown by ur explanation ....really great work..hats off to u
@_Kunal_Pawar
@_Kunal_Pawar 6 ай бұрын
Once again, an outstanding video! Thank you for investing so much effort in breaking down the approach, providing clear pseudocode, illustrating with recursion trees, and finally, implementing the solution. Take good care of your health too! I hope that you are at least getting sleep for 7 to 8 hours.
@Veeshaljha
@Veeshaljha 11 ай бұрын
Understood So well that now I can give tuitions to my college teachers.
@MitaliMaurya-k4x
@MitaliMaurya-k4x 2 ай бұрын
Thankyou for your efforts!! I have never enjoyed learning DSA before the way I enjoy it through your lectures
@studynewthings1727
@studynewthings1727 Жыл бұрын
Thankyou STRIVER, I understood the space complexity of the merge Sort.
@RailExpressbyPreetam
@RailExpressbyPreetam Ай бұрын
What an legit Explaination❤️❤️❤️❤️
@souvikbiswas284
@souvikbiswas284 Ай бұрын
The note section is missing the Python Code, Pasting it here, P.S.: The Merge function is a bit different but the concept is Same. class Solution: def merge(self,arr, l, m, r): # code here arr1 = arr[l:m] arr2 = arr[m: r+1] i = j = 0 while i < len(arr1) or j < len(arr2): if j >= len(arr2): arr[l+i+j] = arr1[i] i += 1 elif i >= len(arr1): arr[l+i+j] = arr2[j] j += 1 elif arr2[j] > arr1[i]: arr[l+i+j] = arr1[i] i += 1 else: arr[l+i+j] = arr2[j] j += 1 def mergeSort(self,arr, l, r): #code here if l==r: return mid = l + (r-l)//2 self.mergeSort(arr, l, mid) self.mergeSort(arr, mid+1, r) self.merge(arr, l, mid+1, r)
@suyashtripathi1818
@suyashtripathi1818 2 ай бұрын
How to say I don't know but you're amazing big bro.as...God of coding world... 👌
@ekta9145
@ekta9145 3 ай бұрын
Thanks for the amazing lecture sir. I've been struggling with consistency for so long. So from now on I'll comment on everything I learn. Trying to get a strong hold of dsa before the intern season starts officially.
@KeshavRaj-w4y
@KeshavRaj-w4y 5 ай бұрын
non other youtubers has such a type of dedication hats off
@factsclub4u
@factsclub4u 2 ай бұрын
06:13 Merge sort is an optimized sorting algorithm. 12:26 Merge Sort is about merging and sorting arrays in a hypothetical manner 18:39 Merge Sort is an algorithm that divides an array into two halves, sorts them, and then merges them. 24:52 Merge Sort Algorithm using Recursion 31:05 Understanding merge sort through pseudocode and dry run 37:18 Explaining the merge sort algorithm 43:31 Merging left and right arrays 49:43 Merge Sort has a time complexity of n*log(n) and a space complexity of n. Crafted by Merlin AI.
@ChandrahasaMutyala
@ChandrahasaMutyala Жыл бұрын
Not just teaching skills but your dedication - recording videos early morning is appreciated
@GaganSingh-zz9el
@GaganSingh-zz9el 11 ай бұрын
bhai inki ya lovebabar kiska dekhu ma
Quick Sort For Beginners | Strivers A2Z DSA Course
35:17
take U forward
Рет қаралды 393 М.
Men Vs Women Survive The Wilderness For $500,000
31:48
MrBeast
Рет қаралды 101 МЛН
🍉😋 #shorts
00:24
Денис Кукояка
Рет қаралды 1,7 МЛН
Minecraft Creeper Family is back! #minecraft #funny #memes
00:26
3 Types of Algorithms Every Programmer Needs to Know
13:12
ForrestKnight
Рет қаралды 471 М.
How to Code The Merge Sort Algorithm in Java
18:38
John Kwisses
Рет қаралды 85 М.
L8. Combination Sum | Recursion | Leetcode | C++ | Java
27:00
take U forward
Рет қаралды 612 М.
How to Do 90% of What Plugins Do (With Just Vim)
1:14:03
thoughtbot
Рет қаралды 895 М.
DSA & ₹1.2 Crore Per Annum Jobs - The Truth? (No Offence)
12:22
CodeWithHarry
Рет қаралды 647 М.
Merge Sort Using Recursion (Theory + Complexity + Code)
49:47
Kunal Kushwaha
Рет қаралды 231 М.
Top 7 Algorithms for Coding Interviews Explained SIMPLY
21:22
Codebagel
Рет қаралды 385 М.
Men Vs Women Survive The Wilderness For $500,000
31:48
MrBeast
Рет қаралды 101 МЛН