DaysInYear - Maple Help

# Online Help

###### All Products    Maple    MapleSim

Calendar

 DaysInYear
 compute the number of days in a given year

 Calling Sequence DaysInYear( year )

Parameters

 year - integer; the year whose length in days is to be computed

Description

 • The DaysInYear( year ) command computes the number of days in the year year. The number of days is either 365 for an ordinary year or 366 in a leap year. There is also an exception for the year 1582, the year of calendar reform, which is missing 10 days.
 • Leap years prior to $1582$ occur every four years.  After $1582$, the modern leap year rules are used.
 • Leap years prior to the year 5 were observed inconsistently, and may be historically incorrect.

Examples

 > $\mathrm{with}\left(\mathrm{Calendar}\right):$
 > $\mathrm{DaysInYear}\left(2000\right)$
 ${366}$ (1)
 > $\mathrm{DaysInYear}\left(1100\right)$
 ${366}$ (2)
 > $\mathrm{DaysInYear}\left(2100\right)$
 ${365}$ (3)
 > $\mathrm{DaysInYear}\left(2001\right)$
 ${365}$ (4)
 > $\mathrm{DaysInYear}\left(1900\right)$
 ${365}$ (5)
 > $\mathrm{DaysInYear}\left(1995\right)$
 ${365}$ (6)
 > $\mathrm{DaysInYear}\left(1582\right)$
 ${355}$ (7)
 > $\mathrm{DaysInYear}\left(0\right)$
 ${366}$ (8)
 > $\mathrm{DaysInYear}\left(4\right)$
 ${366}$ (9)

Compatibility

 • The Calendar[DaysInYear] command was introduced in Maple 2018.
 • For more information on Maple 2018 changes, see Updates in Maple 2018.

 See Also