3 ms·
Yes it is hard. Instead of code points, humans usually handle text by graphemes, which have an arbitrary length in edge cases [0] no matter what encoding is use
by qznc 13y ago
Yes it is hard. Instead of code points, humans usually handle text by graphemes, which have an arbitrary length in edge cases [0] no matter what encoding is used. An O(1) solution for graphemes would be an array of pointers to grapheme objects, which is slower and more memory hungry than necessary in most cases.
[0] http://stackoverflow.com/questions/6579844/how-does-zalgo-text-work http://stackoverflow.com/questions/6579844/how-does-zalgo-te...
- deleted 13y ago[deleted]