643 views

1 Answer

3 3 votes
You can just put the value and verify the answer. I think the answer should be option B because for the question is asking for the largest input we can give so that the problem could be solved in $1sec$. Therefore, for algorithm A if we give the input of size $2^{10^{6}}$, then it is taking $log(2^{10^{6}})=10^{6}\mu s=1sec$. Similarly, for algorithm B, if we give the input of size $10^{^{12}}$, then it is taking $\sqrt{10^{12}}=10^{6}\mu s=1sec$.
Position:
Show:

Related questions

0 0 votes
1 1 answer
1.2k
1.2k views
rsansiya111 asked Dec 20, 2021
1,187 views
Consider the following C program:#include <stdio.h>int r( ){static int num = 7;return num ;}int main ( ) {for (r( ) ;r ( ) ;r ( ) )printf(“ % d”, r( ) );return 0;}Which o...
0 0 votes
1 1 answer
550
550 views
rsansiya111 asked Dec 19, 2021
550 views
0 0 votes
1 1 answer
569
569 views
rsansiya111 asked Dec 17, 2021
569 views
0 0 votes
2 2 answers
778
778 views