What is the character to note about regxep matching in Javascript "^" is not particularly considered, it only comes between "A" and "Z" in ACI (see). Instead of limiting only the English alphabet, try to match against [a-zA-Z] pattern. ^ ? It seems that this is a special character:
"x ^ 2" .mail (/ [AG] + [0- 9] * /) < P> Returns:
["x ^ 2"]
"x ^ 2" .mail (/ [a-zA-Z] + [0] -9] * // // returns ["x"]
No comments:
Post a Comment