mirror of
https://github.com/HowardHinnant/date.git
synced 2025-08-05 05:34:27 +02:00
Updated Examples and Recipes (markdown)
@@ -172,7 +172,8 @@ I want to find all dates for some year `y` which are the 5th Friday of the month
|
|||||||
fifth_friday(date::year y)
|
fifth_friday(date::year y)
|
||||||
{
|
{
|
||||||
using namespace date;
|
using namespace date;
|
||||||
std::array<year_month_day, 5> dates{0_y/0/0, 0_y/0/0, 0_y/0/0, 0_y/0/0, 0_y/0/0};
|
constexpr auto nan = 0_y/0/0;
|
||||||
|
std::array<year_month_day, 5> dates{nan, nan, nan, nan, nan};
|
||||||
unsigned n = 0;
|
unsigned n = 0;
|
||||||
for (auto m = jan; true; ++m)
|
for (auto m = jan; true; ++m)
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user