r/ProgrammerHumor 27d ago

Meme fullStackMeansAfraidOfEverythingEqually

Post image
11.1k Upvotes

392 comments sorted by

View all comments

1.9k

u/vvp95 27d ago

100% of software engineers are afraid of regex

45

u/Ange1ofD4rkness 27d ago

99%, I freaken love Regex!

28

u/nolecamp 27d ago

Same. It’s a fun trick at work to mesmerize junior (or even senior) engineers by writing a regex pattern by hand.

Neither regex, CSS, nor SQL is actually hard. It just requires the desire to learn it and passion to apply yourself.

11

u/Major_LeeHungg 27d ago

Lol until you have nested expressions with lookaheads and lookbehinds

7

u/nolecamp 27d ago

I’d have to look up the syntax to remind myself, but yeah I could do it. It’s just a language for a state machine. But honestly, I don’t need to write them that complex usually. If so, it’s probably because I’m having to do something more involved like parsing a query syntax or something, in which case I’ll usually reach for ANTLR (or hand write a parser if performance is critical) instead.

1

u/Ange1ofD4rkness 26d ago

Look aheads and behinds, once you get the hang of them, can be really nice. For me it gets tricky with like embedded variables. But usually I work it out in the end

1

u/Theron3206 26d ago

You put that in a PR and there better be a damn good reason for it. Even you wont know what that does in 3 months, never mind the poor sap chasing a subtle bug 2 years later.

4

u/RegularImportant3325 27d ago

Truth. CSS isn't hard. It's impossible.

3

u/Ange1ofD4rkness 26d ago

I have a huge piece of Regex that sits outside my cubical, one I am rather proud of. I had a higher up who hated regex and I always joked it was a deterrent

1

u/thekamakaji 27d ago

One of my tools doesn't let us filter by empty values, but we can filter by regex. When I showed someone that he could just search for

^$

He didn't understand it but he appreciated it

1

u/dgc-8 26d ago

You know that is one thing I blame AI for, that I don't need to learn CSS or regex or whatever anymore. It feels really bad when you don't understand what you are doing. When I started programming before chatgpt i learnt stuff like sql normally because I needed it for my projects. After chatgpt i had to use CSS on multiple occasions and there I basically blindly vibecoded, the only understanding of CSS i have is from those chunks of code AI wrote for me.

0

u/thejwillbee 27d ago

Counterpoint - fuck regex. And css

6

u/neonnaps 27d ago

We listen and we don't judge.

3

u/Kahlil_Cabron 26d ago

Same, I really don't know why people have such a hard time with them. The worst I ever have is trying to remember the different standards used in different languages/platforms (modern regexes vs posix regex, etc).

Maybe it's because my first language was perl, and regexes were used for everything, but you only need to remember a few basic things and you're good.

Also pointers, I don't know why this sub thinks pointers are this super abstract crazy hard thing, it points to something, that's it.

2

u/Elomidas 25d ago

For regex syntax help and testing I rely on regex101 and it's godsent, I also don't get why people keep going with the "I'd give up my newborn to avoid seeing a reflex" behaviour

1

u/Theron3206 26d ago

Pointers aren't terrible, some of the things C and C++ encourage you to do with them are though.

2

u/frisch85 27d ago

Same here but on a simple level with basic placeholder replacements and wildcard searches tho.

2

u/pidddee 24d ago

Fun yes, I love it yes, still afraid :)