Created
February 19, 2016 16:54
-
-
Save GeauxEric/52eca45355e01aadce17 to your computer and use it in GitHub Desktop.
regular expression to find all float number in a string
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
s = u'(-1.234, 12]' | |
import re | |
print re.findall(r'[+-]?\d+\.*\d*', s) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment