📅  最后修改于: 2022-03-11 15:01:10.396000             🧑  作者: Mango
string2 = "I love you æç±ä½ "
englishChars = string2.replace(/[^a-z ]/ig, "").trim().split(/\s+/);
nonEnglishChars = string2.replace(/[a-z ]/ig, "").split(/[ ]*/);
final = englishChars.concat(nonEnglishChars);
console.log(final);