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

Should it reverse a BOM as well or keep it first?


Remove it since the BOM is a hack to deal with shitty transfer encodings (i.e. UTF-16LE vs. UTF-16BE) and useless for UTF-8.


Keep it first? Like that’s not a gotcha. Your input is a string and the output is that string visually reversed. What it looks like in memory is irrelevant.




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

Search: