Some people think Go strings are always UTF-8, but they are not: only string literals are UTF-8.
Package gob manages streams of gobs - binary values exchanged between an Encoder (transmitter) and a Decoder (receiver). Package hex implements hexadecimal encoding and decoding.
I need to read a text file that is encoded in GBK. The standard library in Go programming language assumes that all text is encoded in UTF-8.
How can I read files in other encodings?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With