对模式的JavaScript正则表达式的请求

对模式的JavaScript正则表达式的请求,javascript,Javascript,下面是我拥有的字符串,我想使用regex读取数字“10”(在()中的最后一个)。我正在使用Javascript “测试me 234和(另一个)以及测试(10)”类似这样的内容: var str = "test me 234 and the (another) and test (10)"; result = str.match(/\((\d+)\)$/); console.log(result[1]); 学习正则表达式的好资源:

下面是我拥有的字符串,我想使用regex读取数字“10”(在()中的最后一个)。我正在使用Javascript

“测试me 234和(另一个)以及测试(10)”

类似这样的内容:

var str = "test me 234 and the (another) and test (10)";
result = str.match(/\((\d+)\)$/);
console.log(result[1]);

学习正则表达式的好资源: