Already memorised the algo for exam but now that you shown the real life example, it's crystal clear. Thank you sir
Your pedagogy is unique and focused on gate aspirants.. Thank u sir!
Great sir, Computer science has been easy to understand by you only thanks sir
Leagend watching it one day before exam π π π π π
Great lecture sir...All the concepts related to this sorting technique (working,example,complexity) in one video and well explained..Thank you sir
It always helps to write the output in the comments of your first traveral, then the program would run in the first go... public class InsertionSort { public static void main(String[] args) { int[] a = {77, 23, 54, 223, 101, 65, 283, 99, 300, 1}; for (int j = 1; j < a.length; j++) { int newElement = a[j]; //23 int i = j - 1; // 0 while (i >= 0 && newElement < a[i]) { a[i + 1] = a[i]; // {77, 77, ...} i = i - 1; // i = -1 } a[i+1] = newElement; // {23, 77, ...} } // printing the sorted array for (int i = 0; i < a.length; i++) { System.out.println(a[i]); } } }
u are incredible ...one of best tutor on YouTube
Best Teacher ever I have seen on Youtube πAppreciation from Pakistan π΅π°
void insertionSort(int A[], int n) { int i, j, temp; for (i = 1; i < n; i++) { temp = A[i]; for (j = i - 1; j >= 0; j--) { if (A[j] > temp) { A[j + 1] = A[j]; A[j] = temp; } else { break; } } } } code in C of insertion sort algo
Great one!
Sir, your teaching style is so attractive, thank-you. Huge respect from PAKISTAN
Really mja aa gya sir ππ
Amazing ππ
Really sir , you explain all the topics very interesting and also very easily. Even though I don't know "Hindi" I can able to understand each and every word you say , that's crystal clear π Till now , I haven't know how to calculate the Time complexity. But now, I understood only because of you sir I hope this playlist on algorithms should be continued sir :-)
I can see that this code snippet is borrowed from the book called "BIBLE OF ALGORITHMS" ;Introduction TO algo by Thomas. You're literally perfect if you've read that.
Great & Very Helpful Video,Thankyou sir.
Sir thanku so much .your way of teaching awesome sir... Sir u r the key for all engineering students... I wish your channel will grow more and more.... Sir thanku once again.
Real life jitu vaiya ..Thankyou so much
And Most Important Your Teaching style is Amazing I watch Your videos and I Understand each and Everything about Topics
@Nizamkakar