三种基本数据类型:



检测数据类型的方法:

<!DOCTYPE html>
<html lang="en"><head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><title>检测数据类型</title>
</head><body><script>let num = 10console.log(typeof num)let str = 'pink'console.log(typeof str)let str1 = '10'console.log(typeof str1)let flag = falseconsole.log(typeof flag)let unconsole.log(typeof un)</script>
</body></html>
