Skip to main content

days_in_year

Function days_in_year 

Source
pub fn days_in_year(year: u64) -> u64
Expand description

Takes in a year (e.g. 2019) and returns the number of days in that year.

Examples found in repository?
examples/year_days.rs (line 5)
3fn main() {
4    let now = PostEpochTime::now().unwrap();
5    println!("The current year is {}, which has {} days", now.year(), days_in_year(now.year()));
6}