Question 1: Give the worst-case time complexity of the functions below (Big O). Please give a brief justification for yo
Posted: Wed Apr 27, 2022 3:08 pm
Question 1: Give the worst-case time complexity of the functions below (Big O). Please give a brief justification for your answer ) a) def add(b): sum = 0 for p in b: sum+=p print("sum:", sum) add([i for i in range(100)]) b) def fun(number): if number <=1: return number return (fun(number - 1) + fun(number - 2)) for i in range (1, 10): print (fun(i))