day()

本参考资料用于Processing 3.0+。 如果你使用的是前一版本,请在使用软件帮助菜单内的参考资料。. If you see any errors or have suggestions, please let us know. If you prefer a more technical reference, visit the Processing Core Javadoc and Libraries Javadoc.

名称

day()

示例

int d = day();


 // Values from 1 - 31
int m = month();

// Values from 1 - 12
int y = year();


// 2003, 2004, 2005, etc.  String s = String.valueOf(d);

text(s, 10, 28);

s = String.valueOf(m);

text(s, 10, 56);

s = String.valueOf(y);

text(s, 10, 84);

描述 Processing communicates with the clock on your computer. The day() function returns the current day as a value from 1 – 31.
语法
day()
返回值 int
相关 millis()
second()
minute()
hour()
month()
year()

Updated on October 2, 2018 05:02:05pm EDT

day()