From 5785fc662c06a57a55ad91a448567033b12e9f3a Mon Sep 17 00:00:00 2001 From: Jakob Krigovsky Date: Sun, 18 Apr 2021 15:43:06 +0200 Subject: [PATCH] Remove dmonths() exercise (#944) --- datetimes.Rmd | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/datetimes.Rmd b/datetimes.Rmd index ce6f5c6..5dc915c 100644 --- a/datetimes.Rmd +++ b/datetimes.Rmd @@ -539,17 +539,15 @@ knitr::include_graphics("diagrams/datetimes-arithmetic.png") ### Exercises -1. Why is there `months()` but no `dmonths()`? - -2. Explain `days(overnight * 1)` to someone who has just started learning R. +1. Explain `days(overnight * 1)` to someone who has just started learning R. How does it work? -3. Create a vector of dates giving the first day of every month in 2015. +2. Create a vector of dates giving the first day of every month in 2015. Create a vector of dates giving the first day of every month in the *current* year. -4. Write a function that given your birthday (as a date), returns how old you are in years. +3. Write a function that given your birthday (as a date), returns how old you are in years. -5. Why can't `(today() %--% (today() + years(1))) / months(1)` work? +4. Why can't `(today() %--% (today() + years(1))) / months(1)` work? ## Time zones