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
Sonbull [250]
3 years ago
11

Write a function that determines if a given year is a leap year. You can either pass a singleinteger year or your date structure

to this function. Hint: Review Lab 2. 3. Write a function that returns the number of days in a month. Pass your date structure to this function and account for leap years using the function in #2.
Computers and Technology
1 answer:
Elis [28]3 years ago
8 0

A function that determines if a given year is a leap year:

#include<stdio.h>

int main()

{

//fill the code

int year, month;

scanf(“%d %d”,&month,&year);

if(!Leapyear(month, year))

{

if(month == 1 || month == 3 || month == 5 || month == 7 || month == 8 || month == 10 || month == 12)

printf(“Number of days is 31”);

else if(month == 2)

{

printf(“Number of days is 28”);

}

else

printf(“Number of days is 30 “);

return 0;

 }

}

int Leapyear(int month, int year)

{

if((month == 2) && (year%4 == 0) || ((year%100 == 0) &&(year%400 == 0)))

{

printf(“Number of days is 29”);

return 1;

}

else

return 0;

}

You might be interested in
Damage to which portion of the limbic system results in loss of memory of recent events and difficulty committing anything new t
Vera_Pavlovna [14]

Answer:

Hippocampus.

Explanation:

There are two parts of the limbic system. They are the frontal part which is the amygdala and the posterior part which is the hippocampus.

The hippocampus is an extension of the temporal part  of the cerebral cortex which is a plastic-like structure that can be easily damaged by stimuli. It is packed with densed neurons and forms an S-shape at the extension of the temporal part.

It is responsible for learning and memory and damage to it can result to memory loss of recently learnt information.

8 0
3 years ago
If any one answered this i will give brilientst what is stimulation program​
7nadin3 [17]

Explanation:

organized programs of enrichment designed to provide developmentally appropriate activities to babies and toddlers who have, or who are at risk for a variety of conditions (environmentally or biologically caused) that might interfere with their ability to ultimately have a full and productive life."

4 0
3 years ago
A __________ is a combination of software and hardware that links two different types of networks.
timurjin [86]
A computer system is a combination of software and hardware that links two different types of networks
5 0
3 years ago
WHAT ARE THE RISK OF DUST​
Step2247 [10]

Answer:

over heating

Explanation:

in computers dust acts as a blanket which traps heat, excessive heat causes components to burn up and short out

3 0
3 years ago
What is the default file extension for a document created in Word 2016?​
kondaur [170]

docx

Office Open XML (OOXML) format was introduced with Microsoft Office 2007 and became the default format of Microsoft Word ever since. Pertaining file extensions include: .docx – Word document. .docm – Word macro-enabled document; same as docx, but may contain macros and scripts.

7 0
3 years ago
Other questions:
  • Select the correct answer.
    8·1 answer
  • Sarah's employer purchased a health insurance plan that costs $750 per month. Sarah pays $75 toward the plan each month. What is
    5·2 answers
  • 4. How does distance affect the strength of the force of gravity?_
    5·1 answer
  • Releasing refrigerator R -12 into the atmosphere is a criminal offense. A)true B) false
    5·2 answers
  • For the following data, what is the average number of cycles per instruction?
    10·1 answer
  • PLS ANSWER ASAP!
    9·1 answer
  • My cell phone rear camera is dirty does anyone know how to clean it?
    14·2 answers
  • 11. FROM WHICH MENU WOULD YOU BE ABLE TO FIND COLUMNS? *
    11·1 answer
  • What standards organization maintains the ethernet standard?.
    12·1 answer
  • An outpatient provides the following id: barbara jones, birth date 8/15/63. should a specimen be collected for this lab order?
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!