DateTimeOffset.AddYears() Method in C#
This method is used to return a new DateTimeOffset object that adds a specified number of years to the value of the current instance. Syntax: public DateTimeOffset AddYears (int years); Here, it takes a number of years. The number can be negative or positive. Return Value: This method returns an obj