阅读背景:

如何在javascript中将整数格式化为特定长度?

来源:互联网 

I have a number in Javascript, that I know is less than 10000 and also non-negative. I want to display it as a four-digit number, with leading zeroes. Is there anything more elegant than the following?I have a number in Javascript, that I know is l




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: