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

That's actually the kind of solution I thought the author of the article was going to suggest, before I read their solution.

On an unrelated note, why do you use i+1<length rather than i<length-1 ?



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

Search: