Pythex: a Python regular expression editor
文章推薦指數: 80 %
Pythex is a real-time regular expression editor for Python, a quick way to test your regular expressions.
🔗
Linktothisregex
pythex
/
Yourregularexpression:
IGNORECASE
MULTILINE
DOTALL
VERBOSE
Yourteststring:
Todayis2022-07-07.
pythexisaquickwaytotestyourPythonregularexpressions.Trywritingoneortesttheexample.
Matchresult:
Matchcaptures:
Regularexpressioncheatsheet
Specialcharacters
\
escapespecialcharacters
.
matchesanycharacter
^
matchesbeginningofstring
$
matchesendofstring
[5b-d]
matchesanychars'5','b','c'or'd'
[^a-c6]
matchesanycharexcept'a','b','c'or'6'
R|S
matcheseitherregexRorregexS
()
createsacapturegroupandindicatesprecedence
Quantifiers
*
0ormore(append?fornon-greedy)
+
1ormore(append?fornon-greedy)
?
0or1(append?fornon-greedy)
{m}
exactlymmoccurrences
{m,n}
frommton.mdefaultsto0,ntoinfinity
{m,n}?
frommton,asfewaspossible
Specialsequences
\A
startofstring
\b
matchesemptystringatwordboundary(between\wand\W)
\B
matchesemptystringnotatwordboundary
\d
digit
\D
non-digit
\s
whitespace:[\t\n\r\f\v]
\S
non-whitespace
\w
alphanumeric:[0-9a-zA-Z_]
\W
non-alphanumeric
\Z
endofstring
\g
延伸文章資訊
- 1Regular expression issues in .net 6 value converter
There are some missing parts in your regular expression, for example it doesn't have the curly br...
- 2RegExr: Learn, Build, & Test RegEx
Regular expression tester with syntax highlighting, PHP / PCRE & JS Support, contextual help, che...
- 3Convert English to Regex in Google Sheets with GPT3
The script uses OpenAI's GPT3 machine learning model to convert standard English statements into ...
- 4Regex Tester and generator - Beautify Converters
Regex Tester and generator helps you to test your Regular Expression and generate regex code for ...
- 5Regex Tester - Javascript, PCRE, PHP
Test your Javascript and PCRE regular expressions online.