1、‘a’.charCodeAt(index):可返回指定位置的字符的 Unicode 编码
charCodeAt()方法只能分别返回前两个字节和后两个字节的值
‘a’.codePointAt(0)
ES6 提供了codePointAt()方法,能够正确处理 4 个字节储存的字符,返回一个字符的码点。
2、JavaScript split() 方法
split() 方法用于把一个字符串分割成字符串数组
stringObject.split(separator,howmany)
"hello".split("") //可返回 ["h", "e", "l", "l", "o"]
"he llo".split(" ") //可返回 ["he", "llo"]
JavaScript Array join() 方法
var fruits = ["Banana", "Orange", "Apple", "Mango"];
var energy = fruits.join();