Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Let \w+=\w+ = X for readability
- (\w+=\w+;)*(\w+=\w+;?)?
- => (X;)*(X;?)?
- => (X;)*(X|X;)? // ab? => a|ab
- => (X;)*|(X;)*(X|X;) // ab? => a|ab
- => (X;)*|((X;)*X|(X;)*X;) // a(b|c) => ab|ac
- => (X;)*|((X;)*X|(X;)+) // a*a => a+
- => (X;)*|(X;)*X|(X;)+ // a|(b|c) => a|b|c
- => (X;)*|(X;)*X // a*|a+ => a*
- => (X;)*(X)?
- => (\w+=\w+;)?(\w+=\w+)?
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement