JavaScript Program to Check Leap Year Using Conditional Operator || Programmer Shakil

preview_player
Показать описание
Hello Everyone,
kya app web deisgner, web developer, Android Developer, Ios Developer, Software Developer etc. banana chahte hai to is channel par bane rahe is channel par step by step mai apko bataunga.

JavaScript program to check if a given year is leap year

A leap year is a year containing one additional day added to keep the calendar year synchronized with the astronomical or seasonal year. Because seasons and astronomical events do not repeat in a whole number of days, calendars that have the same number of days in each year drift over time with respect to the event that the year is supposed to track. By inserting an additional day or month into the year, the drift can be corrected. A year that is not a leap year is called a common year.
Every year that is exactly divisible by four is a leap year, except for years that are exactly divisible by 100, but these centurial years are leap years if they are exactly divisible by 400. For example, the years 1700, 1800, and 1900 are not leap years, but the year 2000 is.

To determine whether a year is a leap year, follow these steps :

Step-1 : If the year is evenly divisible by 4, go to step 2. Otherwise, go to step 5.
Step-2 : If the year is evenly divisible by 100, go to step 3. Otherwise, go to step 4.
Step-3 : If the year is evenly divisible by 400, go to step 4. Otherwise, go to step 5.
Step-4 : The year is a leap year (it has 366 days).
Step-5 : The year is not a leap year (it has 365 days).

Thank's For Watching This Videos
Рекомендации по теме
Комментарии
Автор

this script for leap year is not correct. For example if you take 1700 as an input, it will show the result as leap year. But 1700 is not a leap year.

mahmudak
Автор

Hm ise 100 or 400 se kyu divide kr rhe hai??

leeza
Автор

Can you do this using ' for loop'

Jjjssjhshhajaaj
Автор

Bhai hindi bhi sahi se nahi bol rahe ho .

Baat to samajh me aa gayi
4 baar dekhne ke baad .

Lekin ek suggestion hai
Hindi movies dekha karo .
Hindi padha karo

androzilla
Автор

Tumhe lagta hai air aur year same hai ?

androzilla
Автор

if your video is in hindi, title it so

TheNoobPube