Regex - Regular Expressions in Perl 5
Regular Expressions or in short Regex, Regexes, or Regexp are one of the most well know parts of Perl.
Regular Expressions in the Perl Tutorial
- Introduction to Regular Expressions in Perl
- Regex: character classes
- Regex: special character classes
- Regex: quantifiers
- Regex videos - part I
- trim - remove leading and trailing spaces
- Perl 5 Regex Cheat sheet
Beginner Perl Maven video course
8. Regular Expressions - part 1
- Regexes
- Where can I use regexes
- Simple use of regex
- Finding a string in a file
- Single character match
- Match any character
- Character classes
- Negated character class
- Optional characters
- Any Number of any Characters
- Quantifiers
- Quantifiers on Character classes
- Exercise: Regexes 1
- Solution: Regexes 1
- Solution: Regexes 2
- Solution: Regexes 3
9. Regular Expressions - part 2
- Regex Alternatives
- Regex Capturing
- Regex Anchors
- More about Character classes
- Special character classes
- Exercise: Match numbers with regex
- Solution: Match numbers with regex
- Exercise: hexa, octal, binary
- Solution: hexa, octal, binary
- Exercise: Roman numbers
10. Regular Expressions - part 3
- m/ for matching regexes
- Case insensitive regexes using /i
- multiple lines in regexes using /m
- Single line regexes using /s
- /x modifier for verbose regexes
- Substitution
- Global substitution with regexes
- Greedy regex quantifiers
- Minimal Regex Matching
- trim
- Fixing assembly with Perl
- split with regex
- Fixing dates using Regexes
- Exercise split HTTP using Regexes
- Solution: split HTTP using Regexes
- Exercise: split path - filename/dirname
- Solution: split path - filename/dirname
- Exercise: sort SNMP numbers
- Solution: sort SNMP numbers
- Exercise: parse hours log file and create time report
- Solution: parse hours log file and create time report (placeholder)
- Exercise: parse INI file
- Solution: parse INI file (placeholder)
- Exercise: parse Perl file
- Solution parse Perl file (placeholder)
Other regex related articles
- Fixing test failure on Windows - Properly quoting regexes - Accepting GitHub pull request
- Perl Regex superpowers - execute code in substitution - what are /e and /ee ?
Published on 2018-03-05
If you have any comments or questions, feel free to post them on the source of this page in GitHub. Source on GitHub.
Comment on this post