hello everybody
i hope you r all good & fine...
b4 2 weeks i had a simple quiz...but i didnt do will....tomorow i will have my medterm ...but i still can not understand the o notation very clear.....
can i have help with those two quistions which i had them in my quiz but i answerd both of them wrongly....=(
1-
input:n=2k for some positive intger k
output:c =number of times
c=0
while n>=1
for j=1 to n
c=c+1
n=n/2
end while
return c
2-
input: a positive integer n
output:c= count of times
c=0
for i=1 to n
M=n/i
for j=1 to m
c=c+1
end for
end for
return c
be4 i have writing this quistions i tryed to solve them...but i am not shur...can anybody help
1_o(n log n)
2-o(n)
thanx