Regular Expressions 101

Library entries

java判断整体多项式的合法性

Vote

1

Regular Expression
javascript

/
(([ ]*[-+]?[ ]*([ ]*([+-]?[ ]*(([1-9]([ ]*[0-9]*)*)[ ]*(\*[ ]*x[ ]*(\^[ ]*([-+]?[1-9][0-9]*))?)?)|([ ]*[-+]?[ ]*x[ ]*(\^[ ]*([-+]?[1-9][0-9]*))?)[ ]*))([ ]*[+-][ ]*([ ]*([+-]?[ ]*(([1-9]([ ]*[0-9]*)*)[ ]*(\*[ ]*x[ ]*(\^[ ]*([-+]?[1-9][0-9]*))?)?)|([ ]*[-+]?[ ]*x[ ]*(\^[ ]*([-+]?[1-9][0-9]*))?)[ ]*))[ ]*)+[ ]*)+)|([ ]*[-+]?[ ]*([ ]*([+-]?[ ]*(([1-9]([ ]*[0-9]*)*)[ ]*(\*[ ]*x[ ]*(\^[ ]*([-+]?[1-9][0-9]*))?)?)|([ ]*[-+]?[ ]*x[ ]*(\^[ ]*([-+]?[1-9][0-9]*))?)[ ]*))[ ]*)
/
gm

Description

Loading markdown...
Submitted by anonymous - a year ago