Community Patterns

Community Library Entry

0

Regular Expression
Created·2020-03-22 11:50
Flavor·Python

r"
^( ([+-]?\d+\.?\d*)| # 1{{.}1} ([+-]?\.\d+)| # .1 ([+-]?(\d*\.)?\d+[eE][-+]?\d+)| # {1{.}}1e1 ([+-]?\d+\.[eE][-+]?\d+) # 1.e1 )$
"
mx
Open regex in editor

Description

All float representations that can be consumed by strtod() (string to double function in c)

Compatible with flex/bison

Submitted by anonymous