[#BloombergLP-bdlt-PosixDateImpUtil-lastDayOfMonth] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdlt.adoc[bdlt]::xref:BloombergLP/bdlt/PosixDateImpUtil.adoc[PosixDateImpUtil]::lastDayOfMonth :relfileprefix: ../../../ :mrdocs: Return the last day of month for the given year and month. == Synopsis Declared in `<bdlt_posixdateimputil.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- static int lastDayOfMonth( int year, int month); ---- == Description Return the last day of the specified `month` in the specified `year`. The behavior is undefined unless `1 <= year <= 9999` and `1 <= month <= 12`. Note that the value returned will be in the range `[ 28 .. 31 ]`. == Return Value last day of the month in `[28 .. 31]` == Parameters [cols="1,4"] |=== | Name| Description | *year* | calendar year in `[1 .. 9999]` | *month* | month of year in `[1 .. 12]` |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#