Check Leap Year Program

if(isset($_POST['submit']))
 {
    $year=$_POST['year'];
    if($year%4==0)
          {
            $leap="It is a leap year";
          }
      else
         {
           $leap="It is not a leap year";
        }
}
 ?>
 


 
 Leap Year
 

 

 


 
 
   
           
   
 
 

Enter the year:  
   

 if(isset($_POST['submit'])){   
                        echo $leap;      }  
     
     ?>   
           

 

In this code output(It is not a leap year) is displaying before entering the input value.

the output should get after giving input value. how to solve it?

0   0
shubhangi kendre
profile Chris 28th October 2026

If you are looking for an addictive arcade challenge that tests your reflexes to the limit, you have to try Space Waves 3D. Every split-second dodge against neon obstacles feels intensely rewarding as the tempo builds. Guiding your arrow through hyper-fast, twisting tunnels requires absolute precision and sharp focus.

profile Suman 22nd October 2026

The Escort in Noida will be ideal for those planning to have dinner, a celebration, or a date with class. It is necessary to speak about the desired place, interests, and expectations before confirmation of the date. Sensuality arises naturally when both adults are comfortable, respectful, and open about boundaries.

Malika
28-10-2026 00:00

This is a simple and useful PHP example for beginners learning conditional statements and form handling. It demonstrates how to retrieve a year from user input and display a result. One important improvement would be to include the full leap year rule, since years divisible by 100 are not leap years unless they are also divisible by 400. Sharing coding examples like this on Facebook programming communities can help beginners learn, exchange ideas, and improve their problem-solving skills. Thanks for sharing!

profile happy 1st September 2026

I was looking for a simple explanation of the piso wifi pause time feature, and this was quite helpful. The steps are easy to follow, especially for users who are trying to understand how the pause option works.

profile happy 31st August 2026

Uma boa publicação para entender melhor o assunto sem precisar de conhecimentos técnicos. Para continuar, basta ver mais conteúdos relacionados.

profile Lindsey 26th August 2026

OmegleChat Turned a Random Stranger into a Lifelong Friend
In a hyper-connected digital world, meaningful conversations can spark in the most unexpected places. While traditional social networks keep us tethered to existing social circles, Omegle opens the door to something entirely different: instant, authentic connections with strangers across the globe.

profile Pisoman 23rd July 2026

Pitchers respond strongly to frustrating errors, runners slide furiously into bases, and players celebrate exhilarating triumphs with infectious enthusiasm on pivotal plays.

baseball 9

profile chynna 2nd July 2026

I found the discussion on RTF editors quite insightful. On another note, I also came across scritchy scratchy, which is a great resource for incremental scratch-card game enthusiasts.

 
profile Christo 22nd June 2026

Understanding leap years is essential for accurate date calculations, and a well-structured program simplifies this. If you're tackling programming challenges, or just enjoy the precision of code, much like mastering the twists and turns in Slope Game, developing a robust leap year checker is a satisfying endeavor. It's a fundamental concept worth perfecting.

profile angela66 12th February 2026

Players can enjoy the satisfaction of upgrading their defenses in steal a brainrot, making their bases increasingly difficult to breach over time.

profile Layne 24th November 2025

Introduction to Monkey Mart
Welcome to the complete guide to Monkey Mart, one of the most exciting and charming supermarket management games available online. Combining business strategy with adorable monkey characters, Monkey Mart invites players to build, manage, and expand their very own bustling supermarket. Whether you’re a casual gamer or a fan of detailed business simulation games, Monkey Mart offers endless fun, creativity, and challenges that test your management skills.

profile Jack 21st October 2025

Space Waves is a rhythmic adventure that blends dazzling graphics, engrossing soundtracks, and quick-paced action, making Space Waves more than just another casual game.

profile Goldstein 17th October 2025

Why Papa’s Freezeria Is Always a Favorite Game
Since its launch, Papa’s Freezeria has always stood out in the Papa Louie series thanks to its smooth gameplay, engaging pace, and the satisfaction of completing the perfect ice cream. Each workday, players will face a more extensive menu, more demanding tastes, and the need for utmost precision in every detail. It’s the combination of speed, precision, and aesthetics that makes this game so appealing.

Jack
21-10-2025 00:00

The game Space Waves appears straightforward at first, but as soon as you start playing, you'll see how difficult and captivating it can be. Rather of emphasizing conventional action or shooting mechanics, Space Waves transports players to a world where movement and sound blend together.

profile Jacob324 4th October 2025

Wordle Unlimited online is more than just a word puzzle—it’s a brain-training game that entertains while improving your language skills. Play Wordle Unlimited free today and enjoy endless word challenges!

profile blacka 20th May 2025

Ready to run through space? Enter Run 3 and explore each challenging planet!

profile Bro 12th May 2025

 [url=http://papasgames3d.com/]Papa's Games[/url] is game guess the song, you can immerse yourself in the world of music 

Related Post