4 ms·
Honestly, as a noob, this is one of the biggest reasons I have such a hard time deciding to learn regex. Python flavor would probably be different than PCRE, w
by justaj 7y ago
Honestly, as a noob, this is one of the biggest reasons I have such a hard time deciding to learn regex.
Python flavor would probably be different than PCRE, which is probably different than JS flavor.
Even worse is that it might be too late to standardize all the regex flavors because there is already so much written in different regex flavors that it just costs too much for them to become obsolete in the future.
This is really demotivating.
- chirss 7y agoHonestly don't let this get you down, here's a learning plan (use regex101 to learn) 1) Learn PCRE regex. 2) Try regex golf or cross words to learn PCRE regex. 3) Take the quiz on regex101. Once you're done with all 3: Learn the minor/major differences in the other languages. There aren't many. For example this named capture group: (?<somename>someregex) Would look like this in a different language: (?P<somename>someregex) There's some differences about what language can and cannot do like recursion because someone thought it was a great idea to make javascript awful at regex, but that's besides the point. Regex is totally worth learning.
- new_guy 7y ago> Honestly, as a noob, this is one of the biggest reasons I have such a hard time deciding to learn regex. Clear your afternoon, and just learn it. Seriously, it takes a couple of hours at best and then - BOOM - you're done for the rest of your life.
- absorber 7y ago> you're done for the rest of your life. If that were so easy then I don't think much of these cheatsheets would exist.
- quickthrower2 7y agoThe basic regex is easy, infact an English word is a regex! A dot matches a single character. Star multiple of the previous character. Just that is useful for a lot of cases!
- freehunter 7y agoThe cheat sheets exist because people aren’t learning regex. You don’t need to learn every flavor of regex, just the one or small number you need to know. And once you know the basics, the differences are very minor.
- olskool 7y agoIf you believe it is possible to become an expert in regular expressions as they exist in modern computer languages in "a couple of hours at best" you are delusional.
- doliveira 7y agoHe didn't say you could become an expert in a single afternoon.