subject

Complete the function ConvertToFeetAndInches to convert totalInches to feet and inches. Return feet and inches using the HeightFtIn struct. Ex: 14 inches is 2 feet and 2 inches.

#include

typedef struct HeightFtIn_struct {
int feet;
int inches;
} HeightFtIn;

HeightFtIn ConvertToFeetAndInches(int totalInches) {
HeightFtIn tempVal;

/* Your solution goes here */

}

int main(void) {
HeightFtIn studentHeight;
int totalInches;

scanf("%d", &totalInches);
studentHeight = ConvertToFeetAndInches(totalInches) ;
printf("%d feet and %d inches\n", studentHeight. feet, studentHeight. inches);

return 0;
}

ansver
Answers: 3

Other questions on the subject: Computers and Technology

image
Computers and Technology, 21.06.2019 22:00, luisanavarrogarcia
Which of the following statements correctly identifies a problem with sanitization methods? a. methods are not available to remove data ensuring that unauthorized personnel cannot retrieve data. b. even fully incinerated media can offer extractable data. c. personnel can perform sanitization steps improperly. d. stored data is physically etched into the media.
Answers: 1
image
Computers and Technology, 23.06.2019 16:00, keyonaemanieevans
Helen is having a meeting with her colleagues in her company. they are working on the goals and objectives for the coming year. they want to ensure that these goals and objectives of the processes involved are properly evaluated. which system can helen and her colleagues apply to evaluate this? helen and her colleagues require a blank to evaluate the goals and objectives.
Answers: 2
image
Computers and Technology, 23.06.2019 17:00, kyleemarie2003
Companies that implement and apply an information system effectively can create
Answers: 1
image
Computers and Technology, 23.06.2019 22:30, kayelynn003
How many points do i need before i can send a chat
Answers: 1
You know the right answer?
Complete the function ConvertToFeetAndInches to convert totalInches to feet and inches. Return feet...

Questions in other subjects: