⭐ in reply to How do I validate a date?
A non-modular way to accomplish this would be to create an array of month lengths, i.e.unless(check_date(param('year'), param('month'), param('day')) { # do something }
which would require one additional check for leap-year.my @month_lengths = (31, 28, 31, 30, ......);
|
|---|