-
Simplified email pattern
start repeat anyof :alphanumeric: + _ . - 1 to inf @ repeat anyof :alphanumeric: . - 1 to inf end
-
Negative, whole, or decimal numbers
start repeat - 0 to 1 repeat :digit: 0 to inf repeat . 0 to 1 repeat :digit: 1 to inf end
-
URL pattern
start http repeat s 0 to 1 :// repeat www. 0 to 1 repeat anyof - :alphanumeric: @ : % . _ \ + ~ # = 2 to 256 . repeat :lowercase: 2 to 6 :boundary: repeat anyof - :alphanumeric: @ : % . _ \ + ~ # ( ) ? / = 0 to inf end
-
Password with 1 lowercase letter, 1 uppercase letter, 1 number,
and contains at least 8 characters
:null: ifnextis repeat :any: 0 to inf and :digit: :null: ifnextis repeat :any: 0 to inf and :alphanumeric: :null: ifnextis repeat :any: 0 to inf and :uppercase: :null: ifnextis repeat :any: 0 to inf and :lowercase: start repeat :any: 8 to inf end
-
Date in the form YYYY/MM/DD from 1900-01-01 to 2099-12-31
start comment -------YEAR 19 or 20 repeat :digit: 2 / comment -------MONTH regex ( 0 range 1 to 9 or 1 anyof 0 1 2 regex ) / comment -------DATE regex ( 0 range 1 to 9 or anyof 1 2 range 0 to 9 or 3 anyof 0 1 regex ) end
Regular Impressions
Regular Impressions is a simple tool for writing regular expressions using a pseudocode-like language.
Created by Zoren Tan.
I made Regular Impressions as a side project in the summer of 2021 after finishing our course about regular expressions. This is just a proof-of-concept project created with my limited skills at that time, to demonstrate a pseudocode-like language as an alternative to writing and storing regular expressions.
Regular Impressions is built with the help of CodeMirror.