Part 1 of understanding regular expressions (regEx).
RegEx is not just useful when writing code ( across different languages they are broadly similar) but I have found knowing a bit allows me to quickly become a “power user” when using the find replace functions in text editors like VSCode and PHPStorm.
If you are using VSCode bring up the “find” box and have a look for the icon .*
So instead of just searching for a text string you can quickly scan more accurately.