Returns the year of a given date.
Syntax:
YEAR(date)
returns the year of date as a number. date may be text or a date-time serial number.
Example:
YEAR("2021-12-01")
returns 2021.
YEAR(A1)
where cell A1 contains the date 1 Dec 2021 as a date-time serial number, returns 2021.