this post was submitted on 25 Oct 2024
109 points (100.0% liked)

xkcd

8784 readers
105 users here now

A community for a webcomic of romance, sarcasm, math, and language.

founded 1 year ago
MODERATORS
 

The number one rule of string manipulation is that you’ve got to specify your encodings.

https://explainxkcd.com/3003/

top 3 comments
sorted by: hot top controversial new old
[–] m_f@midwest.social 19 points 2 weeks ago (1 children)

FYI if you get mojibake like in the alt text, this is a great tool for automatically fixing it:

https://github.com/rspeer/python-ftfy

[–] style99@lemm.ee 8 points 2 weeks ago (1 children)

I thought the garbage symbols were part of the humor of the title.

[–] m_f@midwest.social 10 points 2 weeks ago

Totally. My comment was just a note that if you screw up like the alt text is humorously referring to, that's a good tool for fixing it.