Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我需要一个正则表达式来匹配上升的数字。例如:22335566 66678 但不是:444663 33997777666664
数字的长度不固定,起始数字也不固定。
请问有什么帮助吗?
使用正则表达式实现这一点的最佳方法是:
^(?=\d)1*2*3*4*5*6*7*8*9*$
正则表达式匹配:
(?=\d)