python正则匹配整数和小数

正则如下:re.findall("\d+\.\d+|\d+",s),s为"a10, b1.5"时,返回结果[10, 1.5],具体参考这里

posted @ 2021-01-18 17:04  夏天的冰棍儿  阅读(869)  评论(0编辑  收藏  举报