CamronSmith7731 CamronSmith7731
  • 25-03-2020
  • Computers and Technology
contestada

For an O(Nk ) algorithm, where k is a positive integer, an instance of size M takes 32 seconds to run. Suppose you run an instance of size 2M and find that it takes 512 seconds to run. What is the value of k?

Respuesta :

SerenaBochenek SerenaBochenek
  • 30-03-2020

Answer:

The correct answer to the following question will be "k = 4".

Explanation:

Thus increasing the scale from M - 2 M, and in other words, multiplying the scale increases the time by

[tex]=\frac{512}{32}\\\\=16 \ times[/tex]

Thus, K price is equivalent to 4, which indicates it rises according to a factor of (2)⁴.

Therefore, the complexity of the computation or algorithm is O(N⁴), which indicates that time improves by (2)⁴ times when twice the scale.

Answer Link

Otras preguntas

What was Ramses the second leadership style
your body consists of 7/10 water. is more than 1/2 your body water. explain
What details from the may 15th entry prove that Charlie's intelligence is growing and increasing daily ?
what is the equivalent of 1/50 : fraction , in decimal form
what is the equivalent of 1/50 : fraction , in decimal form
what events led to british defeat at saratoga
Brand A scooter has a top speed that goes 2 miles per hour faster than Brand B. if after hours, Brand A scooter traveled 24 miles, at what rate did Brand B scoo
what events led to british defeat at saratoga
Brand A scooter has a top speed that goes 2 miles per hour faster than Brand B. if after hours, Brand A scooter traveled 24 miles, at what rate did Brand B scoo
4x+5y=20 write this equation in slope intercept form