1 min readfrom Microsoft Excel | Help & Support with your Formula, Macro, and VBA problems | A Reddit Community

Perfect February Year List LAMBDA Challenge

In honor of the perfect month, I slapped together a LAMBDA that lists years in which February's days line up perfectly with weeks. How would you do it?

EDIT: Now with Leap Year support thanks to u/PaulieThePolarBear, who must be feeling very comfortable in this weather.

https://preview.redd.it/1ngod9aupahg1.png?width=1284&format=png&auto=webp&s=4112dcfc5f4c5d034ce19f66cd710284208ae083

=LAMBDA(tminus_years, LET( start_year, YEAR(EDATE(TODAY(),-tminus_years*12)), years, SEQUENCE(tminus_years+1,,start_year), leap_years, MAP(years, LAMBDA(year, MONTH(DATE(year,2,29))=2)), dates, DATE(years,2,1), weekdays, WEEKDAY(dates,1), perfect_years, FILTER(years, (weekdays=1)*(NOT(leap_years))), perfect_years ))(50) 
submitted by /u/bradland
[link] [comments]

Want to read more?

Check out the full article on the original site

View original article

Tagged with

#financial modeling with spreadsheets
#rows.com
#Excel compatibility
#Excel alternatives for data analysis
#no-code spreadsheet solutions
#LAMBDA
#February
#Leap Year
#perfect month
#year
#weeks
#SEQUENCE
#MAP
#FILTER
#WEEKDAY
#EDATE
#dates
#year_list
#perfect_years
#TODAY