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
Crazy boy [7]
3 years ago
13

Write a C program to compute the average age of nth student

Computers and Technology
1 answer:
Hitman42 [59]3 years ago
3 0

Answer:

Following are the code in c language

#include <stdio.h> // header file  

int main() // main function

{

 int n1,i;

 float avg,x,s=0; // variable declaration

printf("\nEnter How many Number terms you want:");

 scanf("%d",&n1); // input terms by user

 for(i=0;i<n1;++i)

{

 scanf("%f",&x); // user input

s= s +x; //calculate sum

}

avg = s/n1;// calculate average of n number

printf("\nThe average of n number is:");

 printf("%f",avg); // display average

return 0;

}

Output

Enter How many Number terms you want:3

3

4

3

The average of n number is:3.333333

You might be interested in
Write the working of dot matrix printer?<br><br>no links<br>​
lbvjy [14]

The working of dot matrix printer is provided in the picture.

4 0
3 years ago
A Network Attached Storage device is good for _____.
igomit [66]

Answer:

sharing data across multiple workstations on the same network

Explanation:

A Network Attached Storage device is good for sharing data across multiple workstations on the same network.

3 0
3 years ago
Read 2 more answers
Which online text source would include a review of a new TV show?
monitta
The answer is a blog....
8 0
4 years ago
Read 2 more answers
For an activity with more than one immediate predecessor activity, which of the following is used to compute its earliest finish
laila [671]

Answer:

The correct option is A

Explanation:

In project management, earliest finish time for activity A refers to the earliest start time for succeeding activities such as B and C to start.

Assume that activities A and B comes before C, the earliest finish time for C can be arrived at by computing the earliest start-finish (critical path) of the activity with the largest EF.

That is, if two activities (A and B) come before activity C, one can estimate how long it's going to take to complete activity C if ones knows how long activity B will take (being the activity with the largest earliest finish time).

Cheers!

7 0
3 years ago
A acrostic sentence for mutualism?
melamori03 [73]
Must have
Understand
Today for
Urgent
Answer
List it too
It's not hard
So listen to
Me
6 0
3 years ago
Other questions:
  • What are the three most important jobs of an operating system?
    8·1 answer
  • What are two most common types of microcomputers? a. IBM-style PCs and Macs c. Clients and Servers b. Mainframes and Minicompute
    14·1 answer
  • What does it mean when information found from web research is valid?
    8·1 answer
  • Name the part of the computer that stores all information and software.
    10·2 answers
  • Any Danganronpa fans around here? I'm bored.
    13·2 answers
  • If you have an ordered list of all the states in North America, and you want to add a title "States of North America", what tag
    14·1 answer
  • Que papel tuvo la innovación en la propagación de la telefonía móvil?​
    7·1 answer
  • Please help me on this I don't know which one they are​
    6·2 answers
  • Question 2 of 10
    15·1 answer
  • A small _____ at the lower right corner of a tool indicates that it contains hidden tools​
    13·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!