CS130-lecture-20200909

Runtime analysis cont. #

IMAGE IMAGE IMAGE IMAGE

Big Oh notation is pretty much the only asymptotic notation used.

IMAGE

Initializing arrays of ints in Java initializes everything to 0, so it is a linear process. The if statement has an else with a loop, so at a worse case it is O(n).

IMAGE IMAGE

On line 73, you have to count the other functions runtime analysis also.

IMAGE IMAGE IMAGE IMAGE