字符串charAt() 刘同玉 2018-06-06 775 阅读1分钟 // charAt 方法可返回指定位置的字符。 var str = 'hello;' console.log(str.charAt(1)); //e console.log(str.charAt(str.length -1) == ';'); // true