I have a list of dates ,and a formula:
January 1, 2017,January 1, 2020,October 1, 2020,July 1, 2021,January 1, 2023
Sequence(2, thisRow.[List of Effective Dates].count()).FormulaMap(CurrentValue.WithName(i,thisRow.[List of Effective Dates].Nth(i).Year() - thisRow.[List of Effective Dates].Nth(i-1).Year() ))
The concept of the formula is it will get the gap years between the dates. For example
2nd date - 1st date, 3rd date - 2nd date, 4th date - 3rd date, 5th date - 4th date.
So, in my example above the gap years are 3, 0, 1 , 2.
Now I want to find which pair of dates gave 0 gap years.