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
Ivenika [448]
3 years ago
7

Define a function SetTime, with int parameters hoursVal and minutesVal, that returns a struct of type TimeHrMin. The function sh

ould assign TimeHrMin's data member hours with hoursVal and minutes with minutesVal.
Computers and Technology
1 answer:
Lapatulllka [165]3 years ago
4 0

Answer:

#include <stdio.h>

typedef struct TimeHrMin_struct //struct

{

int hours;

int minutes;

} TimeHrMin;

struct TimeHrMin_struct SetTime(int hoursVal,int minutesVal) //SetTime function

{

struct TimeHrMin_struct str;

str.hours=hoursVal; //assigning the values

str.minutes=minutesVal;

return str; //returning the struct

}

int main(void)

{

TimeHrMin studentLateness;

int hours;

int minutes;

scanf("%d %d", &hours, &minutes);

studentLateness = SetTime(hours, minutes); //calling the function

printf("The student is %d hours and %d minutes late.\n", studentLateness.hours, studentLateness.minutes);

return 0;

}

Explanation:

You might be interested in
in what way do rules and laws created to address public problems affect individuals groups and business
Anika [276]

Answer:

Explanation:

bussnise

4 0
3 years ago
Find the greatest common factor of 48 and 36.​
gregori [183]

Answer:

Hello, The prime factorization of 48 is: 2 x 2 x 2 x 2 x 3. And The  prime factorization of 36 is: 2 x 2 x 3 x 3.

Explanation:

The prime factors and multiplicities 48 and 36 have in common are: 2 x 2 x 3.

2 x 2 x 3 is the "GCF" of 48 and 36.

"GCF"(48,36) = 12.

7 0
3 years ago
Use sample program from called getopt.c (provided below)
GREYUIT [131]
Beasts shush shrub Nehru need Brid Nehru
6 0
4 years ago
____ can help you determine whether a network is truly under attack or a user has inadvertently installed an untested patch or c
FinnZ [79.3K]

Answer:

Network forensics

Explanation:

hide the most valuable data at the innermost part of the network.

5 0
2 years ago
Dreams is Littlebigplanet 4, change my mind.
kodGreya [7K]

Answer:

It looks like a bean

Explanation:

6 0
3 years ago
Other questions:
  • True or False? In cloud computing, the term "Measured service" refers to a billing model in which gaining access to resources do
    12·1 answer
  • Which are valid double statements for java? double a = 0; double b = -1.0; double c = -425; double d = 6340; double e = -1.0; do
    12·2 answers
  • The programmer must initialize variables when they are declared
    12·1 answer
  • One of the biggest changes to affect the internet will be the continuing adoption of a new version of the internet protocol, ver
    5·1 answer
  • Does anyone know how to connect a nintendo switch to a laptop?
    10·2 answers
  • Question 8 of 10
    9·1 answer
  • Write down a scratch program which:
    5·1 answer
  • What is the most common representation of a distribution?
    14·1 answer
  • Answer this pls ASAP
    11·1 answer
  • Wwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwww!
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!