this post was submitted on 05 Mar 2025
1575 points (99.0% liked)
Programmer Humor
21016 readers
1207 users here now
Welcome to Programmer Humor!
This is a place where you can post jokes, memes, humor, etc. related to programming!
For sharing awful code theres also Programming Horror.
Rules
- Keep content in english
- No advertisements
- Posts must be related to programming or programmer topics
founded 2 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
This is exactly it. Regex is super simple. The difficulty is maintaining a mental mapping between language/util <-> regex engine <-> engine syntax & character class names. It gets worse when utils also conditionally enable extended syntaxes with flags or options.
The hardest part is remembering whether you need to use
\w
or[:alnum:]
.Way too few utils actually mention which syntax they use too. Most just say something accepts a "regular expression", which is totally ambiguous.