Question: Selection Statements Write a C++ function to find whether a given year is a leap year or not. A year is a leap year if

 Selection Statements Write a C++ function to find whether a given

Selection Statements Write a C++ function to find whether a given year is a leap year or not. A year is a leap year if it is evenly divisible by 4, but century years are not leap years unless they are divisible by 400. Prompt the user to enter the year. You may assume the user enters a valid value for year. Do not perform any input error checking. Display a message indicating leap year or not a leap year. Ex: Century years 1700, 1800, and 1900 were not leap years, but the year 2000 was. void leap year (int year)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!