Community Patterns

Community Library Entry

1

Regular Expression
Created·2022-05-28 13:00
Flavor·PCRE (Legacy)

/
^[0-9]{0,4}(?(?=\.)\.\d{0,2})
/
g
Open regex in editor

Description

This helps matching numbers where decimals are optional

Submitted by AndrewEastwood