摘要: // 创建字符串 var str = 'hello world!'; // 通过构造函数的方式 // var str = new String('hello world!'); // 属性方法 // console.log(str.length); // console.log(str.constr 阅读全文
posted @ 2018-04-02 22:40 温柔一刀Trend 阅读(97) 评论(0) 推荐(0) 编辑
摘要: 例子写的不是很完整 大家可以自己运行下 得出结果 进入严格模式 // 'use strict';// var b = 3;// a = 4;// alert(a);一般环境在不添加识别也能识别// 函数环境下// a = 4;// alert(4);// function aaa() {// 'us 阅读全文
posted @ 2018-04-02 22:36 温柔一刀Trend 阅读(341) 评论(0) 推荐(0) 编辑