What is the time complexity of accessing an element by index in an array?
numbers = [10, 20, 30, 40] print(numbers[2])
numbers = [10, 20, 30, 40] print(numbers[2])
Anonymous Quiz
47%
O(1)
53%
O(n)
❤1
Which searching algorithm requires the data to be sorted before searching?
Anonymous Quiz
49%
Linear Search
51%
Binary Search