Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

check regex in python

import re
regExPattern = re.compile("[0-9]")
input1 = "5"
if not re.fullmatch(regExPattern, input1):
    print("input is not a single digit")
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #check #regex #python
ADD COMMENT
Topic
Name
6+5 =