I look at the top of my web browser and see UTF-8 does that mean its better or used more often than a string library or is it just the standard. I don’t understand most functions of UTF-8 but they seem similar to string, so which one is better?
utf-8 is a standard format for storing characters as sequences of bytes (via unicode codepoints). Unless you are messing around with bytes / unicode code points then you shouldn’t really need the utf-8 library directly.
The string library / class is something you should be using whenever you deal with strings. If you were using the utf-8 library for something you’ll probably end up using both.