Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Function which is Big O(1) but not Ω(1)

Can some help me with a function which is Big O(1) but not Ω(1) and the other way around? Some explanation would greatly help.

like image 848
rda3mon Avatar asked Oct 28 '25 03:10

rda3mon


1 Answers

Big-O means <= and big Omega means >=, so a function that is O(1) but not Omega(1) is f(n) = 1/n. For the other way around, f(n) = n works.

like image 125
Keith Randall Avatar answered Oct 30 '25 05:10

Keith Randall