Regex greater than zero with 2 decimal places

后端 未结 5 405
甜味超标
甜味超标 2020-12-02 17:11

I need a RegEx for a numeric value with up to two decimal places greater than zero and may or may not have a zero in the ones column. I should also add....whole numbers are

5条回答
  •  眼角桃花
    2020-12-02 17:56

    This expression will not allow any white spaces in beginning and last

    /^\d*(?:\.\d{1,2})*$/
    

提交回复
热议问题