getCharNum(str,c){
var regex = new RegExp(c, 'g'); // 使用g表示bai整个字符串都要匹配
var result = str.match(regex);
return !duresult ? 0 : result.length;
}
getCharNum(str,c){
var regex = new RegExp(c, 'g'); // 使用g表示bai整个字符串都要匹配
var result = str.match(regex);
return !duresult ? 0 : result.length;
}