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

I see what you're saying, regarding the histogram code. A cleaner approach would have been to store the translations in a named tuple or Dict and iterated through it.

One of the other commenters also mentioned the `replace` function, which could be used in place of a loop.



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

Search: