Professional Documents
Culture Documents
Chapter 6 PDF
Chapter 6 PDF
1
Material for the presentation taken from Cormen, Leiserson, Rivest and
Stein, Introduction to Algorithms, Third Edition; 1
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Part II Sorting and Order Statistics
2
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Sorting algorithms
3
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Sorting algorithms
3
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Sorting algorithms
3
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Sorting algorithms
3
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Binary tree
I Binary tree is a tree data structure where each node can have
at most two child nodes : left child node and right child node.
4
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Full Binary tree
5
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Complete Binary tree
I Leaf nodes are at the same depth and all internal nodes have
2 child nodes
6
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Complete Binary tree
I Leaf nodes are at the same depth and all internal nodes have
2 child nodes
6
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Heap : nearly a complete binary tree
7
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Heap : nearly a complete binary tree
I All levels are completely filled except possibly the last level,
which is filled from the left
7
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Heap : nearly a complete binary tree
8
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Heap : nearly a complete binary tree
8
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Heap : nearly a complete binary tree
I A.length,
8
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Heap : nearly a complete binary tree
I A.length, A.heap-size,
8
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Heap : nearly a complete binary tree
8
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Heap : parent, left child, right child
9
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Binary Heaps
10
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Binary Heaps
10
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Binary Heaps
10
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Binary Heaps
I Min heap
11
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Binary Heaps
I Min heap
I Min-heap property: A[PARENT (i)] ≤ A[i]
11
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Binary Heaps
I Min heap
I Min-heap property: A[PARENT (i)] ≤ A[i]
I A[1] will contain the smallest element
11
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Heap
12
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Heap
12
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Heap
12
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Height of a heap
13
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Height of a heap
13
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Height of a heap
2h
13
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Height of a heap
2h ≤ n
13
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Height of a heap
2h ≤ n ≤ 2h+1 − 1
13
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Height of a heap
2h ≤ n ≤ 2h+1 − 1
2h ≤ n < 2h+1
13
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Height of a heap
2h ≤ n ≤ 2h+1 − 1
2h ≤ n < 2h+1
h ≤ lg n < (h + 1)
13
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Height of a heap
2h ≤ n ≤ 2h+1 − 1
2h ≤ n < 2h+1
h ≤ lg n < (h + 1)
h = blg nc
13
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Maintaining the heap property
14
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Maintaining the heap property
15
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Maintaining the heap property
16
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Finding recurrence
I Let the tree rooted at i have n nodes. The child subtree will
have a size at most 2n/3
17
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Finding recurrence
I Let the tree rooted at i have n nodes. The child subtree will
have a size at most 2n/3
17
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Finding recurrence
I Let the tree rooted at i have n nodes. The child subtree will
have a size at most 2n/3
h = height of node i
Maximum size of child subtree = 2h − 1
17
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Finding recurrence
I Let the tree rooted at i have n nodes. The child subtree will
have a size at most 2n/3
h = height of node i
Maximum size of child subtree = 2h − 1
I Let the tree rooted at i have n nodes. The child subtree will
have a size at most 2n/3
h = height of node i
Maximum size of child subtree = 2h − 1
2h − 1
Maximum fraction of nodes =
2h − 1 + 2h−1
17
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Finding recurrence
2h − 1
Maximum fraction of nodes =
2h − 1 + 2h−1
18
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Finding recurrence
2h − 1
Maximum fraction of nodes =
2h − 1 + 2h−1
a a+1
For b > a > 0 , <
b b+1
18
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Finding recurrence
2h − 1
Maximum fraction of nodes =
2h − 1 + 2h−1
a a+1
For b > a > 0 , <
b b+1
2h − 1
<
2h − 1 + 2h−1
18
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Finding recurrence
2h − 1
Maximum fraction of nodes =
2h − 1 + 2h−1
a a+1
For b > a > 0 , <
b b+1
2h − 1 2h
<
2h − 1 + 2h−1 2h + 2h−1
18
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Finding recurrence
2h − 1
Maximum fraction of nodes =
2h − 1 + 2h−1
a a+1
For b > a > 0 , <
b b+1
2h − 1 2h
<
2h − 1 + 2h−1 2h + 2h−1
2 × 2h−1
=
(2 + 1) × 2h−1
18
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Finding recurrence
2h − 1
Maximum fraction of nodes =
2h − 1 + 2h−1
a a+1
For b > a > 0 , <
b b+1
2h − 1 2h
<
2h − 1 + 2h−1 2h + 2h−1
2 × 2h−1 2
= =
(2 + 1) × 2h−1 3
18
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Finding recurrence
2h − 1
Maximum fraction of nodes =
2h − 1 + 2h−1
a a+1
For b > a > 0 , <
b b+1
2h − 1 2h
<
2h − 1 + 2h−1 2h + 2h−1
2 × 2h−1 2
= =
(2 + 1) × 2h−1 3
2n
Maximum size of child subtree <
3
18
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Maintaining the heap property
19
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Running time
20
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Running time
20
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Running time
20
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Running time
20
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Running time
20
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
MAX-HEAPIFY: Running time
20
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
BUILD-MAX-HEAP : Building a heap
21
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
BUILD-MAX-HEAP : Building a heap
21
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
BUILD-MAX-HEAP : Building a heap
22
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
BUILD-MAX-HEAP : Building a heap
22
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
BUILD-MAX-HEAP : Building a heap
22
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
BUILD-MAX-HEAP : Running time
23
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
BUILD-MAX-HEAP : Running time
Running time:
23
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
BUILD-MAX-HEAP : Running time
23
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
BUILD-MAX-HEAP : Running time
23
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
24
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
l n m
I There are at most nodes having a height h.
2h+1
24
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
l n m
I There are at most nodes having a height h.
2h+1
h = 0,
24
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
l n m
I There are at most nodes having a height h.
2h+1
10
h = 0,
20+1
24
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
l n m
I There are at most nodes having a height h.
2h+1
10
h = 0, = 5;
20+1
24
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
l n m
I There are at most nodes having a height h.
2h+1
10
h = 0, = 5; h = 1,
20+1
24
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
l n m
I There are at most nodes having a height h.
2h+1
10 10
h = 0, = 5; h = 1, =3
20+1 21+1
24
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
l n m
I There are at most nodes having a height h.
2h+1
10 10
h = 0, = 5; h = 1, =3
20+1 21+1
h = 2,
24
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
l n m
I There are at most nodes having a height h.
2h+1
10 10
h = 0, = 5; h = 1, =3
20+1 21+1
10
h = 2, = 2;
22+1
24
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
l n m
I There are at most nodes having a height h.
2h+1
10 10
h = 0, = 5; h = 1, =3
20+1 21+1
10
h = 2, = 2; h = 3,
22+1
24
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
l n m
I There are at most nodes having a height h.
2h+1
10 10
h = 0, = 5; h = 1, =3
20+1 21+1
10 10
h = 2, = 2; h = 3, =1
22+1 23+1
24
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
I Proof by Induction
25
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
I Proof by Induction
I Base case: h = 0
25
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
I Proof by Induction
I Base case: h = 0 lnm
Number of nodes having zero height =
2
25
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
I Proof by Induction
I Base case: h = 0 lnm l n m
Number of nodes having zero height = ≤ h+1
2 2
25
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
I Proof by Induction
I Base case: h = 0 lnm l n m
Number of nodes having zero height = ≤ h+1
2 2
I Inductive step: l n m
Assume that there are at most (h−1)+1 number of nodes
2
of height h − 1.
25
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
I Proof by Induction
I Base case: h = 0 lnm l n m
Number of nodes having zero height = ≤ h+1
2 2
I Inductive step: l n m
Assume that there are at most (h−1)+1 number of nodes
2
of height h − 1.
Let kh be the number of nodes of height h in the binary heap
T.
25
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
I Proof by Induction
I Base case: h = 0 lnm l n m
Number of nodes having zero height = ≤ h+1
2 2
I Inductive step: l n m
Assume that there are at most (h−1)+1 number of nodes
2
of height h − 1.
Let kh be the number of nodes of height h in the binary heap
T.
Let us construct a new heap T 0 by removing all leaf nodes
from T
25
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
I Proof by Induction
I Base case: h = 0 lnm l n m
Number of nodes having zero height = ≤ h+1
2 2
I Inductive step: l n m
Assume that there are at most (h−1)+1 number of nodes
2
of height h − 1.
Let kh be the number of nodes of height h in the binary heap
T.
Let us construct a new heap T 0 by removing all leaf nodes
from T
0
kh = kh−1
25
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
I Proof by Induction
I Base case: h = 0 lnm l n m
Number of nodes having zero height = ≤ h+1
2 2
I Inductive step: l n m
Assume that there are at most (h−1)+1 number of nodes
2
of height h − 1.
Let kh be the number of nodes of height h in the binary heap
T.
Let us construct a new heap T 0 by removing all leaf nodes
from T
n0
0
kh = kh−1 ≤ (h−1)+1
2
25
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
I Proof by Induction
I Base case: h = 0 lnm l n m
Number of nodes having zero height = ≤ h+1
2 2
I Inductive step: l n m
Assume that there are at most (h−1)+1 number of nodes
2
of height h − 1.
Let kh be the number of nodes of height h in the binary heap
T.
Let us construct a new heap T 0 by removing all leaf nodes
from T
n0
0 b(n/2)c
kh = kh−1 ≤ (h−1)+1 = (h−1)+1
2 2
25
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
I Proof by Induction
I Base case: h = 0 lnm l n m
Number of nodes having zero height = ≤ h+1
2 2
I Inductive step: l n m
Assume that there are at most (h−1)+1 number of nodes
2
of height h − 1.
Let kh be the number of nodes of height h in the binary heap
T.
Let us construct a new heap T 0 by removing all leaf nodes
from T
n0
0 b(n/2)c
kh = kh−1 ≤ (h−1)+1 = (h−1)+1
2 2
(n/2)
≤
2h
25
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
l n m
Nodes with height h ≤ h+1
2
I Proof by Induction
I Base case: h = 0 lnm l n m
Number of nodes having zero height = ≤ h+1
2 2
I Inductive step: l n m
Assume that there are at most (h−1)+1 number of nodes
2
of height h − 1.
Let kh be the number of nodes of height h in the binary heap
T.
Let us construct a new heap T 0 by removing all leaf nodes
from T
n0
0 b(n/2)c
kh = kh−1 ≤ (h−1)+1 = (h−1)+1
2 2
l
(n/2) n m
≤ =
2h 2h+1
25
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
BUILD-MAX-HEAP : Running time
26
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
BUILD-MAX-HEAP : Running time
blg nc l
X n m
h+1
O(h)
2
h=0
26
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
BUILD-MAX-HEAP : Running time
blg nc l blg nc
X n m X h
O(h) = O n
2h+1 2h
h=0 h=0
26
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
BUILD-MAX-HEAP : Running time
blg nc l blg nc
X n m X h
O(h) = O n
2h+1 2h
h=0 h=0
∞
X
kx k
k=0
26
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
BUILD-MAX-HEAP : Running time
blg nc l blg nc
X n m X h
O(h) = O n
2h+1 2h
h=0 h=0
∞
X x
kx k =
(1 − x)2
k=0
26
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
BUILD-MAX-HEAP : Running time
blg nc l blg nc
X n m X h
O(h) = O n
2h+1 2h
h=0 h=0
∞
X x
kx k =
(1 − x)2
k=0
∞
X
k(1/2)k
k=0
26
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
BUILD-MAX-HEAP : Running time
blg nc l blg nc
X n m X h
O(h) = O n
2h+1 2h
h=0 h=0
∞
X x
kx k =
(1 − x)2
k=0
∞
X 1/2
k(1/2)k =
(1 − (1/2))2
k=0
26
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
BUILD-MAX-HEAP : Running time
blg nc l blg nc
X n m X h
O(h) = O n
2h+1 2h
h=0 h=0
∞
X x
kx k =
(1 − x)2
k=0
∞
X 1/2
k(1/2)k = =2
(1 − (1/2))2
k=0
26
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
BUILD-MAX-HEAP : Running time
blg nc l blg nc
X n m X h
O(h) = O n
2h+1 2h
h=0 h=0
∞
!
X h
=O n
2h
h=0
26
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
BUILD-MAX-HEAP : Running time
blg nc l blg nc
X n m X h
O(h) = O n
2h+1 2h
h=0 h=0
∞
!
X h
=O n
2h
h=0
= O(2n)
26
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
BUILD-MAX-HEAP : Running time
blg nc l blg nc
X n m X h
O(h) = O n
2h+1 2h
h=0 h=0
∞
!
X h
=O n
2h
h=0
= O(2n) = O(n)
26
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
P∞ k x
k=0 kx = (1−x)2
27
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
P∞ k x
k=0 kx = (1−x)2
I 0<x <1, 1 + x + x2 + . . .
27
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
P∞ k x
k=0 kx = (1−x)2
1
I 0<x <1, 1 + x + x2 + . . . =
1−x
27
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
P∞ k x
k=0 kx = (1−x)2
1
I 0<x <1, 1 + x + x2 + . . . =
1−x
∞
X 1
I xk =
1−x
k=0
27
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
P∞ k x
k=0 kx = (1−x)2
1
I 0<x <1, 1 + x + x2 + . . . =
1−x
∞
X 1
I xk =
1−x
k=0
I Differentiating both sides w.r.t x
∞
X 1
kx k−1 =
(1 − x)2
k=0
27
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
P∞ k x
k=0 kx = (1−x)2
1
I 0<x <1, 1 + x + x2 + . . . =
1−x
∞
X 1
I xk =
1−x
k=0
I Differentiating both sides w.r.t x
∞
X 1
kx k−1 =
(1 − x)2
k=0
27
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Heap
28
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Heapsort
29
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Heapsort
29
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Heapsort
29
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Priority Queues
30
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Priority Queues
30
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Priority Queues
30
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Priority Queues
30
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Priority Queues
30
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Priority Queues
30
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Priority Queues
30
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Priority Queues
30
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Priority Queues
31
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Priority Queues
31
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Priority Queues
32
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Heap-Increase-Key
33
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Heap-Increase-Key
33
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Heap-Increase-Key
33
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Max-Heap-Insert
34
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Max-Heap-Insert
34
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
Priority Queue
35
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms
I
36
BITS-Pilani K. K. Birla Goa Campus Data Structures and Algorithms