Skip to main content

Regular Expressions

  • A regular expression that extracts the numbers in a numbered list
^\d+\.\s
  • A regualar expression that find two line breaks in a row
\n\n
  • A regular expression that finds the first word in a sentence
\w+
  • A regular expression that find offensive words in a sentence
\b(fuck|shit|damn|bitch|
  • A regular expression that finds lines that don't start with a number
^\D