神奇的JavaScript (1)

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/KimSoft/article/details/52636947

直接看代码,心里想想输出结果:

document.write("<br>new Date() > new Date()   := " + (new Date() > new Date()));
document.write("<br>new Date() < new Date()   := " + (new Date() < new Date()));
document.write("<br>new Date() >= new Date()  := " + (new Date() >= new Date()));
document.write("<br>new Date() <= new Date()  := " + (new Date() <= new Date()));
document.write("<br>new Date() == new Date()  := " + (new Date() == new Date()));
document.write("<br>new Date() === new Date() := " + (new Date() === new Date()));

结果来了:

new Date() > new Date()   := false
new Date() < new Date()   := false
new Date() >= new Date()  := true
new Date() <= new Date()  := true
new Date() == new Date()  := false
new Date() === new Date() := false
阅读更多

没有更多推荐了,返回首页