想到一个快速判断字符串某几个某字符出现次数的方法 split
let str = "1212a1212a1212"
let times = str.split("a").length - 1
15