Skip to content

Files

Latest commit

0429af0 · Sep 18, 2014

History

History

python2.7

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
Sep 18, 2014
Sep 18, 2014
Sep 18, 2014

Environment

OS: Linux

Editor: SublimeText

Interpreter: python (2.7)

Execution: python skeleton.py

Regular Expressions (Meat)

General Goals to make use of Regular Expressions

  • How to show whether an expression matches (or not) a string
  • Use multiple modifiers for one regex (case insensitive, multiline, etc...)
  • Show how to split a string into an array with a regex defined delimiter
  • Show how to parse/capture individual peices of a string using regex
  • Show how to do a Find-and-Replace using regex

The goal of this is not to teach how to do regular expressions in general; the goals are to support the implementation of regular expression in the language you choose to use. In other words "I know how regex works, but what is the syntax this language uses for a regex 'split'"

The Regular Expression example script is called re.py