retagged by
377 views
0 votes
0 votes

f(n)>=c1.n

h(n)=c2.n

then why answer cant be O(n),It is given as C

retagged by

1 Answer

0 votes
0 votes
f(n) = omega (n) which means  f(n) >=n   [ f(n) should be either n or more than n ]   ['n' , 'n+1' , 'n+2'......]

g(n) = O(n) which means g(n) <=n             [ g(n) should be either n or less than n ]    [ '1' , '2' , '3' ........ 'n']

h(n) =  which means h(n)  = n                   [h(n)  and n both are equal]   ['n']

since f(n) + g(n) >= n

therefore f(n) + g(n) = omega(n)
edited by
Answer:

Related questions

3.1k
views
2 answers
3 votes
Rishav Kumar Singh asked Jul 25, 2018
3,075 views
What is the time complexity of following function fun()? Assume that log(x) returns log value in base 2.void fun() { int i, j; for (i=1; i<=n; i++) for (j=1; j<=log(i); j...
956
views
1 answers
2 votes
gauravkc asked Apr 5, 2018
956 views
What is the time complexity of this code?
415
views
1 answers
2 votes
92komal asked Jan 26, 2018
415 views
plz help me . how to solve that type of question
332
views
1 answers
1 votes