jacquiii8772 jacquiii8772
  • 22-08-2019
  • Computers and Technology
contestada

)in the link based implementation of the ADT sorted list what is the worst case time efficiency of the remove method?

A. O(1)

B.O(logn)

C.O(n)

D.O(n2)

Respuesta :

ExieFansler ExieFansler
  • 27-08-2019

Answer:

C.O(n).

Explanation:

The worst case time complexity of remove method in linked list based implementationof  ADT  sorted list  is O(n) . The worst  case would be  when you  have to remove the  element that is placed at the end.So we have to traverse  the whole  list and reach upto that node then remove that node or element.

Answer Link

Otras preguntas

What is 123x45= I really need help
Managers are a critical part of any successful organization because​ ________. a. they are generally good at leading by example b. they are most familiar with t
a colony contains 1500 bacteria. the population increases at a rate of 115% each hour. if x represents the number of hours elapsed, which function represents th
f(x)=5×-2; translation 5 units right
The formula p = nc - e  gives the profit p when a number of items n are each sold at a cost c and expenses e are subtracted. If p = 3750, n = 3000 and e = 900,
What are five kinds of evidence you can use to determine if a chemical reaction has occurred?
If the sum of four numbers is 144, what is the average of the four numbers
The burning of wood is an example of an oxidation-reduction reaction
explain why streets and highways have speed limits rather than velocity limits
What type of reforms would fall under Social Welfare?