Hacker News new | ask | show | jobs
by userbinator 4556 days ago
UTF-8 is variable length in that it can be anywhere from 1 to 4 bytes, while UTF-16 can either be 2 or 4. That makes a UTF-16 decoder/encoder half as complex as a UTF-8 one.
1 comments

Surrogate pairs are way more complex than anything in UTF-8.