Excel FunctionsLesson 82Free preview
DATEDIF
This lesson is part of Excel · All levels
Summary
DATEDIF is an Excel hidden function for calculating the difference between two dates in a given unit. The unit parameters are "Y" (year), "M" (month), or "D" (day), as well as variants "MD", "YM", and "YD" for the remaining days or months. This function does not appear on the automatic recommendation list but is still usable.
Key points
- Syntax: DATEDIF(tanggal_awal, tanggal_akhir, satuan)
- Units Y, M, and D count years, months, or full days
- MD counts the remainder of the day, the remainder of the month, and the remainder of the day between years
- The start date must be before the end date for the results to be correct
Full lesson
Code examples and quizzes
Full lessons, code examples, and quizzes are available to subscribers. 5 questions.