Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I'm not honestly sure I can. I can certainly do merge sort and a really naive quicksort, but bubblesort's not something I've ever written, nor have I even seen a description of the algorithm since my freshmen year of college or earlier. The name isn't exactly descriptive, so if I were asked to implement it I'd probably take my best stab at it and wind up implementing some other O(n^2) sort. Does that make me a bad programmer?


If you can do any real sort algorithm in real code off the top your head, bubble sort shouldn't matter, and any interviewer who punts you for that is interviewing for a job you don't want.




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

Search: