3 ms·
Don't learn it. Regex is not something you need to remember. Just build the regex you need with ChatGPT along with an online regex tester.
by andrewstuart 2y ago
Don't learn it. Regex is not something you need to remember.
Just build the regex you need with ChatGPT along with an online regex tester.
- gwbas1c 2y agoI 2nd that! (I came here to say the same thing.) I personally don't work much with regexes, so usually, when I need one, I ask ChatGPT to make one, and it comes back with something good. FWIW: I've seen some regexes used as a source of truth: The regex both processed data, and then determining what settings a user created required parsing the regexes. I quickly refactored that code to store what the setting was.
- levocardia 2y agoCame here to say this. I always knew regex was something I was going to have to learn, and procrastinated for a long time because I dreaded it. I kept kicking the can down the road until one day ChatGPT came along and solved that problem permanently.
- Minor49er 2y ago"Don't learn it" is generally bad advice for anyone seeking knowledge. Your suggestion will also lead to missing important edge cases where matches may incorrectly hit or miss on unexpected inputs. The basics of regex are really not that difficult to grasp anyways
- andrewstuart 2y agoNevertheless, regex is something that there's little benefit in developing deep knowledge of - it tends to be use to solve specific pattern matching problems and there are great tools that will give you an answer to your problem.
- Minor49er 2y agoFor pattern matching, that tool is called Regex :^)