Question: 3. [10 minutes] Consider the code below, where myList is implemented as a array. Give the big-Oh worst-case time cost of this method, in terms
![3. [10 minutes] Consider the code below, where myList is implemented](https://dsd5zvtm8ll6.cloudfront.net/si.experts.images/questions/2024/09/66f5b944846db_78066f5b94406487.jpg)
3. [10 minutes] Consider the code below, where myList is implemented as a array. Give the big-Oh worst-case time cost of this method, in terms of n which is the length of myList. (also, justify your answer) public int myMethod (List myList) int cntr = 0; for (int i = 0; i myList . size ( ); i += 1) { for (int j 0: j
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
