undefined is returned when you use either a variable that has been declared but never had a value assigned to it or an object property that does not existnull is usually considered a special value of object typea value that represents no objectnull更多的是强调其类型不同于string,object,array,boolean等。
null是指变量或对象属性存在但未初始化(没有有效值)或赋予null值的
alert(null==undefined);//true
alert(null === undefined);//false