adplus-dvertising
frame-decoration

Question

If for an algorithm time complexity is given by O(n) then complexity of it is:

a.

constant

b.

linear

c.

exponential

d.

none of the mentioned

Answer: (b).linear

Engage with the Community - Add Your Comment

Confused About the Answer? Ask for Details Here.

Know the Explanation? Add it Here.

Q. If for an algorithm time complexity is given by O(n) then complexity of it is:

Similar Questions

Discover Related MCQs

Q. If for an algorithm time complexity is given by O(log2n) then complexity will:

Q. If for an algorithm time complexity is given by O(1) then complexity of it is:

Q. To measure Time complexity of an algorithm Big O notation is used which:

Q. The worst case complexity of quick sort is

Q. The worst case complexity for insertion sort is

Q. The complexity of Fibonacci series is

Q. What does it mean when we say that an algorithm X is asymptotically more efficient than Y?

Q. The worst case occur in quick sort when

Q. Let m, n be positive integers. Define Q (m, n) as Q (m, n) = 0, if m>n Then Q (m, 3) is (a div b, gives the quotient when a is divided by b)

Q. Using the standard algorithm, what is the time required to determine that a number n is prime ?

Q. Which of the following sorting algorithms does not have a worst case running time of O(n2)?

Q. The concept of order (Big O) is important because

Q. The time complexity of an algorithm T(n), where n is the input size, is given by T( n) = T( n - 1) + 1/n if n > 1 The order of this algorithm is

Q. A text is made up of the characters a, b, c, d, e each occurring with the probability .12, .4, .15, .08 and .25 respectively. The optimal coding technique will have the average length of

Q. The running time of an algorithm is given by T(n) = T(n - 1) + T(n - 2) - T(n - 3), if n > 3 n, otherwise.

Q. The order of an algorithm that finds whether a given Boolean function of 'n' variables, produces a 1 is

Q. An algorithm is made up of 2 modules Ml and M2. If order of M1 is f(n) and M2 is g(n) then the order of the algorithm is

Q. Six files Fl, F2, F3, F4, F5 and F6 have 100,200,50,80, 120, 150 number of records respectively. In what order should they be stored so as to optimize access time? Assume each file is accessed with the same frequency.

Q. The running time of an algorithm T(n),where 'n' is the input size, of a recursive algorithm is given as follows.is given by T(n) =c + T(n - 1), if n > 1 d, if n ≤ 1 The order of this algorithm is

Q. An array of n numbers is given, where n is an even number. The maximum as well as the minimum of these n numbers needs to be determined. Which of the following is TRUE about the number of comparisons needed?