Hacker News new | past | comments | ask | show | jobs | submit login

I also thought what was humorous was if you were using python, you wouldn't use a python sorting algorithm for numbers. I realize it is just an example, but if you want something realistic, use the built in sort which is nicely optimized, or write your own method in C if it is non-trivial.

  >def realsort():
    t1 = datetime.datetime.now()
    for x in range(3000):
        numbers[:].sort()
    t2 = datetime.datetime.now()
    print t2-t1
  >realsort()
  >0:00:00.128081



Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: