37.6k views
0 votes
Which of the following functions grows at a faster rate than the rest? (Points : 6)

n2
n
n log n
log n

User Sunil Rk
by
6.4k points

1 Answer

5 votes

Answer:

n2.

Step-by-step explanation:

The function with the time complexity of n2 is the fastest growing function is in terms of square.As n increases the time complexity will grow very rapidly.

n=1 n2=1

n=2 n2=4

n=3 n2=9

n=4 n2=16

n=5 n2=25.

The slowest growing function among them is log n then n and then n log n.

n log n is better than n2.

User Veelen
by
6.5k points