From e94868a695f12c5b7917040987e2e3dc6c831b27 Mon Sep 17 00:00:00 2001 From: FURK4NGG <105324908+FURK4NGG@users.noreply.github.com> Date: Tue, 18 Feb 2025 17:06:10 +0300 Subject: [PATCH] Update 1.js --- JAVASCRIPT/tr/1.js | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/JAVASCRIPT/tr/1.js b/JAVASCRIPT/tr/1.js index ebe4c79..4c5de18 100644 --- a/JAVASCRIPT/tr/1.js +++ b/JAVASCRIPT/tr/1.js @@ -46,13 +46,11 @@ images[currentIndex].classList.add('visible'); async function getCurrentYear() { const now = new Date(); const currentYear = now.getFullYear(); - const currentMonth = now.getMonth() + 1; // 0-11 olduğu için +1 ekliyoruz + const currentMonth = now.getMonth() + 1; let age = currentYear - 2006; - // Eğer şu an Mart'tan önceki bir aydayız, yaşı bir azaltıyoruz - if (currentMonth < 3) { - age -= 1; - } + + if(currentMonth < 3){age -= 1;} return age; }