Solved

In Questions fiNd the "Best" Big-O Notation to Describe the Complexity

Question 12

Short Answer

In questions find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following:
1, log2n,n,nlog2n,n2,n3,,2n,n!\log _ { 2 } n , n , n \log _ { 2 } n , n ^ { 2 } , n ^ { 3 } , \ldots , 2 ^ { n } , n !
-The number of print statements in the following: i:=1,j:=1 while in while ji print "hello"; j:=j+1i:=i+1\begin{array} { l } i : = 1 , j : = 1 \\\text { while } i \leq n \\\text { while } j \leq i \\\text { print "hello"; } \\j : = j + 1 \\i : = i + 1\end{array}

Correct Answer:

verifed

Verified

Unlock this answer now
Get Access to more Verified Answers free of charge

Related Questions