JS的最初版本是这样区分的:null表示一个“无”的对象,转换为数值时为0;undefined表示一个“无”的原始值,转换为数值时为NaN
而现如今,null被当作原本就不应有值,常见用法有:
undefined表示“缺少值”,即此处应该有值,但还未定义。常见用法有: