subject

Define a function SetBirth, with int parameters monthVal and dayVal, that returns a struct of type BirthMonthDay. The function should assign BirthMonthDay's data member month with monthVal and day with dayVal.

#include

typedef struct BirthMonthDay_struct {
int month;
int day;
} BirthMonthDay;

/* Your solution goes here */

int main(void) {
BirthMonthDay studentBirthday;
int month;
int day;

scanf("%d %d", &month, &day);
studentBirthday = SetBirth(month, day);
printf("The student was born on %d/%d.\n", studentBirthday. month, studentBirthday. day);

return 0;
}

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 07:00
What are three software programs for mobile computing?
Answers: 1
question
Computers and Technology, 23.06.2019 11:30
Me dangers of social media and the internetexplain what each means: 1) social media and phones have become an addiction.2) outside people have access to you all the time.3) cyberstalking4) cyberbullying5) catphishing6) viruses7) identity theft8) credit card fraud9) hacking10) money schemes
Answers: 1
question
Computers and Technology, 23.06.2019 12:00
3. when you right-click a linked spreadsheet object, what commands do you choose to activate the excel features? a. linked worksheet object > edit b. edit data > edit data c. linked spreadsheet > edit d. object > edit data
Answers: 2
question
Computers and Technology, 23.06.2019 16:00
Does read theory have answers keys ?
Answers: 1
You know the right answer?
Define a function SetBirth, with int parameters monthVal and dayVal, that returns a struct of type B...
Questions
question
Biology, 15.12.2020 20:00
question
Mathematics, 15.12.2020 20:00
question
Mathematics, 15.12.2020 20:00
question
English, 15.12.2020 20:00
question
Mathematics, 15.12.2020 20:00
Questions on the website: 13722361