I want to match string ending with ')' . I use pattern :
"[)]" or ".*[)]"
It should match the string :
x=main2.addMenu('Edit')
But it doesn't work. What is wrong ?
The only matches a position at a word boundary. Think of it as a (^w|w$|Ww|wW) where w is any alphanumeric character and W is any non-alphanumeric character. The parenthesis is non-alphanumeric so won't be matched by .
(^w|w$|Ww|wW)
Just match a parethesis, followed by the end of the string by using )$
)$
1.4m articles
1.4m replys
5 comments
57.0k users