Page 1 of 1

What’s the time complexity of this loop: for (int j=n; j > 0; j/ = 2 ) cout<< j << endl; Group of answer choices A.) O

Posted: Fri Jul 08, 2022 6:43 am
by answerhappygod
What’s the time complexity of this loop:
for (int j=n; j > 0; j/ = 2)
cout<< j <<endl;
Group of answer choices
A.) O (n log n)
B.) O(log n)
C.) O (n2)
D.) O (n)