All mock tests are FREE till 31 December — register to save your progress
Unit 7 · Data Structures and Algorithms Paper 2 CS · November 2020

If algorithm A and another algorithm B take −− log (n) √n 2 and microseconds, respectively, to n solve a problem, then the largest size of a problem these algorithms can solve, respectively, in one second are ___ and _____

Pick an option to check yourself, or open the answer below.

Show answer & explanation

Correct answer: B. 2^(10⁶) and 10¹²

Explanation

One second is 10⁶ μs. log₂ n = 10⁶ gives n = 2^(10⁶); √n = 10⁶ gives n = 10¹².

More Data Structures and Algorithms questions