Assume that an algorithm that takes log2 n microseconds to solve a problem.find the largest input size n such that algorithm solves the problem in time 24 days. 21400000 21440000 21444000 21404040
Answers
Answered by
48
Answer:
Since the given algorithm is based on time in microseconds, let us convert 24 days into microseconds:
Days into microseconds ---> multiply the time value by 8.64e+10
24 days = 24 × 8.64e+10 = 2.074e+12 microseconds
log₂(n) = 2.074e+12 microseconds
To remove log₂ from left side, take 2^(x) on right hand side of equation.
n = 2^{2.074e+12}
n = 2^(2000000000000) is the largest input size.
Similar questions