Assuming that N is very large, can anybody help me in ordering the following list for Big O running times from Slowest to Fastest.
O(N^2)
O(N)
O(1)
O(N!)
O(2^N)
O(N log N)
O(N^3)
O(log N)
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Divide O(A/B) to see if O(A) is asymptotically larger than O(B). (Take the limit as n->infinity. For example N^2/N = N, which blows up to infinity, so N^2>N asymptotically. Alternately, N/N^2 = 1/N which approaches 0, so N
Then you can graph them to check your work and get intuition (though graphs like this can easily “lie” if you graph them too close to the origin, and/or there are smaller hidden terms).