Unit 7
Unit 8
Unit 9
Time Complexities
Misc.
100
List the properties of a tuple 

fixed length, can hold any type, accessed via indices 

100

Do insertion sort on the board for the following data: [19,4,2,17,9,6,15,1,0,13,7]

[0,1,2,4,7,9, 13, 15, 19]

100

What are 2 ways to resolve collisions? 

chaining and open addressing
100

What is the best, average and worst case of quick sort

O(nlogn), O(nlogn) O(n^2)

100

What does the data look like in the best and worst case of insertion sort.

Already sorted and completely reversed.
200

Which function adds to the end of a list. which function removes from a list. 

.append(), .remove()

200

What is this called: A function that performs a comparison between two values a and b 

comparator 

200

Hash functions never have collisions : True or false

False

Why?

200

What are the time complexties of the fplowing list functions: append, remove, concatenation, extend 

O(c), O(n) for the rest


200
What are the 2 hashing data structures 

dictionaries and sets

300

What does the : operator do, and what is it called.

Slicing, is creates a list from an existing list.
300

Do merge sort on the following data: [6,2,18,3,9,7,11,2,5,10]

Idk I’ll check the board. 

300

Name 2 properties of a set

unique elements and unordered

300

What is the best, worse, and average case of insertion sort

O(n), O(n^2)

300

What is the time complexity of inserting into a dictionary and set. 

O(c)

400

Which function can append a list onto another list

Extend (+=)

400

Do quick sort on the following data : [8,4,2,10,11,5,6,7]

ill check the work on the board 

400

name 2 properities of a dictionary 

key value pairs, unique keys 

400

What is the best, average and worst case of merge sort

O(nlogn)

400
what is one thing you should check before this exam that is not content related?

whether you have any finals conflicts

500

Which type of value has this functionality: When the elements inside the list are changed in a function, the changes are permanent and persist after the function returns 

reference types 

500

Sorted() and sort() use which type of sorting algorithm. 

Timsort 

500

name the set operations and what they do.

Union, Intersection, difference 

500

What affects the time complexities of quick sort?

where the pivot lies in the data 

500

What types should keys in a dictionary be?

ANY TYPE !!

M
e
n
u