⌊1/𝑛⌋ - represents the floor function Does the floor or ceiling function affect the complexity under which a function falls?
⌊1/𝑛⌋∈Θ(1/𝑛) or to Ω(log𝑛)
Found this interesting question in a Cornell paper
Thanks
⌊1/𝑛⌋ - represents the floor function Does the floor or ceiling function affect the complexity under which a function falls?
⌊1/𝑛⌋∈Θ(1/𝑛) or to Ω(log𝑛)
Found this interesting question in a Cornell paper
Thanks
Neither of those. For $n>1$, $\lfloor\frac{1}{n}\rfloor=0$. Hence, $\lfloor\frac{1}{n}\rfloor=0=O(0)$.
Also, you can easily rule out $\Omega(\log(n))$ since $\log$ is an increasing to infinity, while $\frac{1}{n}$ is a decreasing function.