From d3f6fb1e8f59b62b03ab82fcd0ca62b28bb40ad3 Mon Sep 17 00:00:00 2001 From: Raphael Date: Sun, 8 Jun 2025 16:00:22 +0200 Subject: [PATCH] fix(09/00): wrong order at each time --- cpp09/ex00/main.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cpp09/ex00/main.cpp b/cpp09/ex00/main.cpp index 90dde9d..9a96d3b 100644 --- a/cpp09/ex00/main.cpp +++ b/cpp09/ex00/main.cpp @@ -6,7 +6,7 @@ /* By: rparodi +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2025/04/08 12:15:32 by rparodi #+# #+# */ -/* Updated: 2025/06/05 19:30:36 by rparodi ### ########.fr */ +/* Updated: 2025/06/08 15:59:57 by rparodi ### ########.fr */ /* */ /* ************************************************************************** */ @@ -133,7 +133,7 @@ std::string check_date(std::string name, enum error_code *error_code) { } if (day > "28") { if (month == "02" && day == "29") { - if ((atoi(year.c_str()) % 4 == 0) && (atoi(year.c_str()) % 100 != 0 || atoi(year.c_str()) % 400 == 0)) + if (!((atoi(year.c_str()) % 4 == 0) && (atoi(year.c_str()) % 100 != 0 || atoi(year.c_str()) % 400 == 0))) *error_code = NO_DATE; } else {