mayeshanidhi mayeshanidhi
  • 27-02-2024
  • Computers and Technology
contestada

for (int i = 1; i < n; i = i*2)

---------for (int j = 0; j < i; j = j+2)

---------------Sum[i] += j * Sum[i];


What is the tight bound big-Oh time complexity in terms of n in each case? Show
all necessary steps.


(I GET IT THE OUTER LOOP IS log(n), BUT I'M CONFUSED ABOUT THE INNER AND THE TOTAL)

Respuesta :

Otras preguntas

Are squirrel monkeys unicellular or multicellular?
Write the expanded form od 8,374 using the exponential notation.
What new system of national government did the delegates agree upon at the constitutional convention of 1787?
What does pululaba mean?
what was the last straw for mccarthy in the eyes to the american public
you buy a lily and an african violet on the same day.  You are instructed to water the lily every fourth day and water the violet every seventh day after taking
How might a country with only one valuable resource develope its economy?
True or False: The plants, animals, people, and land in the eastern and western parts of North America are the same.
14-(2x+5)=-2x+9 [help?]
what is 5/8 x 24 in simplest form