1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Pachacha [2.7K]
3 years ago
5

#A year is considered a leap year if it abides by the #following rules: # # - Every 4th year IS a leap year, EXCEPT... # - Every

100th year is NOT a leap year, EXCEPT... # - Every 400th year IS a leap year. # #This starts at year 0. For example: # # - 1993 is not a leap year because it is not a multiple of 4. # - 1996 is a leap year because it is a multiple of 4. # - 1900 is not a leap year because it is a multiple of 100, # even though it is a multiple of 4. # - 2000 is a leap year because it is a multiple of 400, # even though it is a multiple of 100. # #Write a function called is_leap_year. is_leap_year should #take one parameter: year, an integer. It should return the #boolean True if that year is a leap year, the boolean False #if it is not. #Write your function here!

Computers and Technology
1 answer:
lara [203]3 years ago
5 0

Answer:

To check if the year comes under each 100th year, lets check if the remainder when dividing with 100 is 0 or not.

Similarly check for 400th year and multiple 0f 4. The following C program describes the function.

#include<stdio.h>

#include<stdbool.h>

bool is_leap_year(int year);

void main()

{

int y;

bool b;

 

printf("Enter the year in yyyy format: e.g. 1999 \n");

scanf("%d", &y);     // taking the input year in yyyy format.

 

b= is_leap_year(y);  //calling the function and returning the output to b

if(b==true)

{

 printf("Thae given year is a leap year \n");

}

else

{

 printf("The given year is not a leap year \n");

}

}

bool is_leap_year(int year)

{

if(year%100==0)   //every 100th year

{

 if(year%400==0)   //every 400th year

 {

  return true;

 }

 else

 {

  return false;

 }

}

if(year%4==0)  //is a multiple of 4

{

 return true;

}

else

{

 return false;

}

}

Explanation:

Output is given as image

You might be interested in
what term defines inventiveness uncertainty and futuristic ideas typically deals with science and technology
Kruka [31]

Answer:

Innovation.

Explanation:

Innovation can be considered the ideal term, because an innovative idea arises from the set of a new technique, method or invention that aims to improve an existing method, standard, or product.

However, added to an innovative idea is the risk, since innovation breaks an already established standard, so it is through science and technology that an invention will gain greater foundation and recognition, which increases its credibility and acceptance.

3 0
3 years ago
At regular intervals the AP in an infrastructure network or wireless device in an ad hoc network sends a ____ frame both to anno
pshichka [43]

Answer:

beacon

Explanation:

At regular intervals the AP in an infrastructure network or wireless device in an adhoc network sends a beacon frame both to announce its presence and to provide the necessary information for other devices to join the network.

5 0
3 years ago
Which fact does lean green eco machines present to show that electric cars are not perfect
Yuri [45]

Answer: HOPE THIS HELPED YOU! :D ;)

Eco cars are still too expensive for most car buyers

Explanation:

5 0
3 years ago
Read 2 more answers
What is the slowest shutter speed?
crimeas [40]

Answer: I think the answer would be 1/30 or 1/60

Explanation: Anything below 1/90 is considered a soft image so i would go with 1/30 Brainliest ans plz.

7 0
3 years ago
A(n) ________ is a box consisting of a radio receiver/transmitter and antennas that links to a wired network, router, or hub.
melomori [17]

A(n) access point is a box consisting of a radio receiver/transmitter and antennas that links to a wired network, router, or hub.

<h3>What is an access point?</h3>

An access point is known to be a kind of device that makes a wireless local area network, or WLAN, and it is often done in an office or big  building.

Therefore, A(n) access point is a box consisting of a radio receiver/transmitter and antennas that links to a wired network, router, or hub.

Learn more about access point from

brainly.com/question/14306861

#SPJ12

6 0
2 years ago
Other questions:
  • To calculate the chapter from which you must solve the programming exercise, divide the integer number representing your student
    10·1 answer
  • I would A lot of knowledge and education for computers and <br> Technology
    10·2 answers
  • Given: The following if statement uses an overloaded &gt; operator to determine whether the price of a Car object is more than $
    5·1 answer
  • Signing up for a(n) ____ will automatically provide you with web content that is updated on a regular basis.
    15·1 answer
  • How to download a software program??
    15·1 answer
  • What does it mean to be self demanding?
    12·1 answer
  • When you print a worksheet or use the Page Setup dialog box, Excel inserts __ breaks that show the boundaries of what will print
    7·1 answer
  • Select the correct answer. Vlad wants to include his goals and target in his résumé. He also wants to add how he can be benefici
    12·1 answer
  • What should you do if you forget your root password for MySQL?
    13·1 answer
  • How many domains are there in the classification system?
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!