This commit is contained in:
Igor Dzuro 2020-03-27 05:17:48 +01:00
parent 3f743a0312
commit 92cd2cd6e7
2 changed files with 7 additions and 5 deletions

Binary file not shown.

View File

@ -33,15 +33,17 @@ int datevalid(int d, int m, int y) {
return 0;
}
if(m == 2) {
if(isleap(y)) {
if(d <= 29) {
return 1;
if (m == 2) {
if (isleap(y)) {
if (d > 29) {
return 0;
}
} else {
if (d > 28) {
return 0;
}
}
}
if ( m == 4 || m == 6 || m == 9 || m == 11 ) {
if(d <= 30) {