Complexity Analysis Flashcards

1
Q

Implementation of Binary Search Tree

A

Children Pointers

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

BST insert

A

0(n)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

BST delete

A

O(n)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

BST Search

A

O(n)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

BST deleteMin

A

O(n)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

BST deleteMax

A

O(n)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Building BST using insert

A

O(n^2)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Building optimal BST using dynamic programming algorithm

A

O(n^3)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Implementation of 2-3 Tree

A

Children/parent pointers

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

2-3 Tree insert

A

O(lgn)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

2-3 Tree delete

A

O(lgn)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

2-3 Tree search

A

O(lgn)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

2-3 Tree findMin

A

O(lgn)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

2-3 Tree findMax

A

O(lgn)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

2-3 Tree buildTree

A

O(nlgn)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

implementation of k-heap

A

array-based

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

k-heap insert

A

O(lgn)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

k-heap general delete

A

O(n)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

k-heap general search

A

O(n)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

min k-heap deleteMax

A

O(n)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

min k-heap deleteMin

A

O(lgn)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
Q

max k-heap deleteMax

A

O(lgn)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
23
Q

max k-heap deleteMin

A

O(n)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
24
Q

k-heap top-down build

A

O(nlgn)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
25
k-heap bottom-up build
O(n)
26
k-heap frequent insertions
want larger k
27
k-heap frequent deletions
want smaller k
28
dual-heap insert
O(lgn)
29
dual-heap deleteMin
O(lgn)
30
dual-heap deleteMax
O(lgn)
31
dual-heap findMin
O(1)
32
dual-heap findMax
O(1)
33
dual-heap buildHeap
O(n)
34
implementation of minmax/maxmin heap
sequential array-based with root at A[1]
35
minmax/maxmin heap insert
O(lgn)
36
minmax/maxmin deleteMin
O(lgn)
37
minmax/maxmin deleteMax
O(lgn)
38
minmax/maxmin top-down build
O(nlgn)
39
minmax/maxmin bottom-up build
O(n)
40
minmax/maxmin findMin
O(1)
41
minmax/maxmin findMax
O(1)
42
implementation of leftist heap
children pointers
43
leftist heap concate
O(lgn)
44
leftist heap insert
O(lgn)
45
leftist heap deleteMin (for min leftist)
O(lgn)
46
leftist heap deleteMax (for max leftist)
O(lgn)
47
leftist heap findMin (for min leftist)
O(1)
48
leftist heap findMax( for max leftist)
O(1)
49
leftist heap buildHeap using insert
O(nlgn)
50
implementation of skew heap
children pointers
51
skew heap concate
O(n)
52
skew heap insert
O(n)
53
skew heap deleteMin (for min skew heap)
O(n)
54
skew heap deleteMax (for max skew heap)
O(n)
55
skew heap findMin (for min skew heap)
O(1)
56
skew heap findMax( for max skew heap)
O(1)
57
skew heap buildHeap using insert
O(n^2)
58
implementation of pairing heap
left-child right-sibling pointers
59
pairing heap merge
O(1)
60
pairing heap insert
O(1)
61
pairing heap findMin (for min pairing heap)
O(1)
62
pairing heap findMax (for max pairing heap)
O(1)
63
pairing heap deleteMin (for min pairing heap)
O(n)
64
pairing heap deleteMax (for max pairing heap)
O(n)
65
pairing heap buildHeap using insert
O(n)
66
What structure(s) are search trees?
binary search trees | 2-3 trees
67
What structure(s) are priority queues?
k-heaps
68
What structure(s) are double-ended priority queues?
dual-heaps | minmax/maxmin heaps
69
What structure(s) are concatenated queues?
leftist heaps skew heaps pairing heaps
70
Binomial Queue concate
O(lgn)
71
Binomial Queue insert
O(lgn)
72
Binomial Queue deleteMin
O(lgn)
73
Binomial Queue findMin
O(lgn)
74
Binomial Queue Build
O(nlgn)
75
Fibonacci Heap concate
O(1)
76
Fibonacci Heap insert
O(1)
77
Fibonacci Heap deleteMin
O(n)
78
Fibonacci Heap findMin
O(1)
79
Fibonacci Heap decreaseKey
O(lgn)
80
Fibonacci Heap delete
O(n)
81
AVL tree find
0(lgn)
82
AVL tree findMin
O(lgn)
83
AVL tree findMax
O(lgn)
84
AVL tree delete
O(lgn)
85
AVL tree deleteMin
O(lgn)
86
AVL tree deleteMax
O(lgn)
87
AVL tree insert
O(lgn)