https://towardsdatascience.com/everything-you-need-to-know-about-regular-expressions-8f622fe10b03 Everything you need to know about Regular Expressions What is a Regular Expression? On an abstract level a regular expression, regex for short, is a shorthand representation for a set. A set of strings. Say we have a list of all valid zip codes. Instead of keeping that long and unwieldy list around, it’s often more practical to have a short and precise pattern that completely describes that set. Whenever you want to check whether a string is a valid zip code, you can match it against the pattern. You’ll get a true or false result indicating whether the string belongs to the set of zip codes the regex pattern represents. Let’s expand on the set of zip codes. A list of zip codes is finite, consists of rather short strings, and is not particularly challenging computationally. What about the set of strings that end in .csv ? Can be quite useful when looking for data files. This set ...