Let's say you never really learn regex. You know how and when to use it, but you never quite get past needing tools and search engines.
Is that okay? Is it necessary to advance past this point? Why or why not?
Let's say you never really learn regex. You know how and when to use it, but you never quite get past needing tools and search engines.
Is that okay? Is it necessary to advance past this point? Why or why not?
For further actions, you may consider blocking this person and/or reporting abuse
Jimmy McBride -
Ingo Steinke, web developer -
Emanuele Bartolesi -
Bek Brace -
Top comments (41)
In a previous job, there was a regex wizard. Things were good. He was wise. We could go to him, present him with a problem, and he would write a solution on some yarn (Slack).
A short while after he left, I found myself with a problem that regex could solve. I was left with Google. So I hacked. I copied and pasted and used the regex-helper websites as I ran around the china shop that is string parsing, smashing everything as I went.
I didn't know it at the time but when I searched and hacked a solution together, I was learning bits and bobs. Stray phrases of advice stuck me with. Occasionally and without knowing it I would find myself on a tech blog explaining the intricacies of search patterns.
Then one day someone who had seen some of my diffs approached me and requested a regex solution. Without knowing it I had become the wizard. An expert who knew almost nothing.
It would have been quicker just to learn the theory from the start! π
Take the problem as an oportunity to learn, to explore and prove to yourself that isn't "magic" and you can be the "wizard" too...
This is how I feel a huge amount of engineering seniority develops. It comes in small spurts and builds up over years, frequently we don't even realize how much we know.
I jump between languages a lot. I have to Google the most rudimentary things all the time. For the most part, I know what I need to do and how to do it, but remembering the exact function names and syntax for all the languages, libraries and frameworks I use is impossible.
I also strongly agree with what you have said. Its impossible to remember or memorize A-Z all the time about any thing.
Yeah, I find myself searching for standard library stuff all the time when I swap languages.
It's good to know how they work, but sometimes you get method or function names mixed up in your head.
I believe there is nothing like "never really learn".
There is just "no enough motivation".
I realized that when I was asked to explain regex to validate data in the frontend for new comers.
I couldn't stand the idea of explaining "poorly" in front of many people, so I looked up regex thoroughly to avoid any embarrassing situation.
That was my enough motivation to learn regex, and I reflect this story to any "never able to learn" situation as "no enough motivation".
There are a lot of very good comments on this post. I think many can be summed up as you should learn what you use frequently but that it's okay to have a broad and shallow appreciation of many topics that you can google. Turning that around you should understand and gain expertise in the things you use every day.
My grandfather told me that you are not paying a teacher to make chalk marks on the blackboard. You are paying them for what they know and their skill in explaining it. Knowing what to google is a similar situation. One big difference between a programmer who is struggling to get started and one who can be thrown any task is knowing just enough to google.
A couple of decades ago you needed to read the right books. Until google and stackoverflow you needed to read the right websites and forums. More recently to get up to speed on some new tech you need to watch the right YouTube channels.
I would suggest if anyone finds themselves googling too often for something they should watch a few videos about it. I recommend using a player that lets you speed up the playback to as fast as you can comprehend then skip back and slow down anything you missed. Some techs will always require deep knowledge, for example cryptography, but mainstream technology competes for mindshare by being accessible. After a bit of video research you can google like a boss and with a bit of experience you can be highly proficient in most mainstream tech.
I think it's a great place to start with anything. If you need something frequently enough, you'll start to remember it.
So for example, I'm quite new to Elixir, and the backend at my job is written in it. I went through most of the getting started guide quite quickly, and then dove into the code base. The basics of defining modules and functions stuck quite quickly, but I still need to google for things like
case
andcond
statements, and standard library functions.I think where actively learning things by following tutorials works best is for unknown unknowns. You might not know that a particular type of solution is out there, so you don't know to Google for it.
Everyone searches for syntax from time to time!
I like your point about determining unknown unknowns with tutorials.
I am usually against Regex in general, things can get quite out of hand if one doesn't fully understand how it works and use it, especially if it passes tests (covering happy paths) and reaches production π±.
But to answer the question, I personally have been in situations where I needed to Google to find something which was close enough to what I needed and then used a couple of online regex checkers to validate what I was writing. And I am one of those who believe it's really rare that you know everything about a topic. So even if I feel confident, I always do a bit more research (Google, find someone expert, use a tool, etc) Β―_(γ)_/Β―
Regex is a powerful tool, but as every Tobey Maguire fan knows: With great power, comes great responsibility.
It took me a full 2 minutes to understand the title. LOL
Seriously now, I keep my own personal documentation for everything I study. Taking notes on everything is a great way to remember it, so I rarely actually go through them; but as it's organized the way I understand it, it's easier to find what I'm looking for. Otherwise, I use DuckDuckGo :D
DuckDuckGo users unite!
There are literally dozens of us!
Letβs turn that into hundreds π
We need software to help us write software for the same reasons people need the software we write. We write the software so that it can do for someone what they would do manually or store whatever they would remember. Google, in turn, stores the details we would otherwise have to remember in order to build such software. We remember what to Google or use bookmarks or other software to remember what we Googled for us. I suppose at some point we have to actually remember something, but why clutter our heads with stuff we can store on someone else's shelf?
My level of knowledge with regexes is likely much higher than most peoples'. I'm a Perl guy, and this is one of the things that sets Perl apart.
I know that there's mechanisms commenting within Perl regexes (but not, if I understand, Perl Compatable Regular Expressions (PCRE), which is what other languages import). I have decided that if your regex is that far along, your problem domain has become too complex. You might be trying to parse HTML or something.
But beyond that, much simpler regexes have buggy behavior, including this lightning talk from a year ago, where a friend explains an issue with the regex engine that I kinda understand as I listen, but forget soon after the video ends.
So, while I have drank deeply from the kool-aid, I understand those who might just sip.
To put it another way, Larry Wall (the person who committed the code with the regex bug) says it's okay to speak Baby Perl, and so, who am I to say that speaking Baby Regex is a problem?
Regex is a difficult thing to say you master because, depending on the DSL, different characters are interpreted differently. I would say you never get past needing tools in this scenario because it probably isn't something your day-to-day work requires. And that's true for anything someone would decide to google.
Even if I felt totally confident in my regex, I'd still check it online.