为什么直接输出就是数字相加,是number型,调用函数就是字符型的了
var udate = new Date()
var n=udate.getFullYear();
var y=udate.getMonth()+1;
var r=udate.getDate();
var s=udate.getHours();
var f=udate.getMinutes();
var m=udate.getSeconds();
document.write(r+s+f);
var udate = new Date()
var n=udate.getFullYear();
var y=udate.getMonth()+1;
var r=udate.getDate();
var s=udate.getHours();
var f=udate.getMinutes();
var m=udate.getSeconds();
document.write(r+s+f);
2021-04-05
举报