01_js数据类型

JavaScript数据类型:

 1 <script type="text/javascript">
 2             var age = 30; //number
 3             var nikename = 'zhangsan' //string
 4             var result = true; //真假
 5             var teshu = undefined; //未赋值
 6             var teshu2 = null; 
 7             
 8             
 9             //判断数据类型
10             console.log(typeof(age));
11             console.log(typeof(nikename));
12             console.log(typeof(teshu));
13             console.log(typeof(teshu2));
14 </script>

 

posted @ 2020-08-05 15:53  jaysonzxk  阅读(85)  评论(0编辑  收藏  举报