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

I’d say it’s more common for iterator-based loops to run to completion than to hit a `break` statement. The `StopIteration` exception is how the iterator signals that completion.




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

Search: