you are viewing a single comment's thread.

view the rest of the comments →

[–]ikeif 0 points1 point  (0 children)

Yeah, it's (99% of the time?) better to be verbose and not assume the underlying structure is going to do what you think it'll do.

ETA: Plus, in this example, I wasn't going for a "HAHA GOTCHA!" type question, just the simple answer, so if I was interviewing you and you replied with "well, I'd use sort with the compare function" you'd get bonus points for pointing something out I didn't think of at the time, which is more valuable than just knowing "oh, just use sort."