Search for a tool
Regular Expression Simplificator

Tool to simplify a regex. Regexp simplificator (or regular expression) shortens the string of characters to search for patterns in a text.

Results

Regular Expression Simplificator -

Tag(s) : Data Processing

Share
Share
dCode and more

dCode is free and its tools are a valuable help in games, maths, geocaching, puzzles and problems to solve every day!
A suggestion ? a feedback ? a bug ? an idea ? Write to dCode!


Please, check our dCode Discord community for help requests!
NB: for encrypted messages, test our automatic cipher identifier!


Thanks to your feedback and relevant comments, dCode has developed the best 'Regular Expression Simplificator' tool, so feel free to write! Thank you!

Regular Expression Simplificator

Regular Expressions Simplification


Answers to Questions (FAQ)

How does the regexp minification works ?

The regular expressions simplifier (beta version) replaces useless elements in a regular expression in order to minimize it or make it more readable by analyzing patterns component of the regex string.

Example: x{0,} is equivalent to x* through simplification

Example: [aaabbb] is equivalent to [ab]

Example: (ab|ac) can also be written a[bc]

Some regular expressions can not be simplified. In this case, the program will return the same string.

The program/optimizer is in beta test, and does not work all the times! More, some parentheses, potentially useful for capturing can be deleted and escape characters can be ignored.

How to reduce the size of a regexp?

There are shorthand character classes and metacharacters:

abbreviationequivalent
\d[0-9]
\w[A-Za-z0-9_]
\s[ \t\r\n\f]
\D[^\d]
\W[^\w]
\S[^\s]

The letter d for digit (digit), w for word (letter / alphanumeric character) and s for space (spacing), uppercase letters represent the negation of the set

Example: D for a character that is not a number, etc.

Source code

dCode retains ownership of the online "Regular Expression Simplificator" source code. Except explicit open source licence (indicated CC / Creative Commons / free), the "Regular Expression Simplificator" algorithm, the applet or snippet (converter, solver, encryption / decryption, encoding / decoding, ciphering / deciphering, translator), or the "Regular Expression Simplificator" functions (calculate, convert, solve, decrypt / encrypt, decipher / cipher, decode / encode, translate) written in any informatic language (Python, Java, PHP, C#, Javascript, Matlab, etc.) and all data download, script, copy-paste, or API access for "Regular Expression Simplificator" are not public, same for offline use on PC, tablet, iPhone or Android ! Remainder : dCode is free to use.

Need Help ?

Please, check our dCode Discord community for help requests!
NB: for encrypted messages, test our automatic cipher identifier!

Questions / Comments

Thanks to your feedback and relevant comments, dCode has developed the best 'Regular Expression Simplificator' tool, so feel free to write! Thank you!


Source : https://www.dcode.fr/regular-expression-simplificator
© 2021 dCode — The ultimate 'toolkit' to solve every games / riddles / geocaching / CTF.
Feedback