week 9 Flashcards

1
Q

When Node to remove has both left and right subtree

A

sucessor can either be :

largest value in the left subtree or smallest value in right subtree

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

Binary Search Tree Removal william fiset

A

Do the last 2 Additional questions on the youtube video

From 12:20 onwards

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

The map ADT (get, put, remove)
 get(k): if the map M has an entry e=(k,o) with key k,
return its associated value o; else, return null;

 put(k,o): If M does not have an entry (k, o) then add
it to the map M and return null; else, replace with o
the existing value of the entry with key equal to k and
return old value associated with k;

 remove(k): if the map M has an entry with key k,
remove it from M and return its associated value; else,
return null;

A

READ

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