"Coding is just like talking to a unknown girl. Once you talked to her with guts, the next time you'll never afraid",Really? Yes , try it Now !!!
Everything here is for education and learning purpose only , individual holds rights on outer posts/links etc.
Team Cracking The Code
minHeapify(int i) { int l = left(i); int r = right(i); int largest; if (l < heap_size && arr[l] < arr[i]) largest = l; else largest = i; if (r < heap_size && arr[r] < arr[largest]) largest = r; if (largest != i) { swap(&arr[i], &arr[largest]); minHeapify(largest); } }
No comments :
Post a Comment