answersLogoWhite

0

Still curious? Ask our experts.

Chat with our AI personalities

JudyJudy
Simplicity is my specialty.
Chat with Judy
RafaRafa
There's no fun in playing it safe. Why not try something a little unhinged?
Chat with Rafa
EzraEzra
Faith is not about having all the answers, but learning to ask the right questions.
Chat with Ezra

Add your answer:

Earn +20 pts
Q: What is the program to calculate the average of first 'n' natural numbers?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Continue Learning about Math & Arithmetic

An example of a PASCAL program to find the average of a set of numbers?

how to get the arithmetic average on pascal


How can you form a program of finding the average of five numbers?

to find the average (a.k.a mean) of any set of numbers you add all of the numbers up, then divide by however many numbers there are. for ex: 2,7,5,9,4 1st step: 2+7+5+9+2= 25 2nd step: 25 divided by 5= 5 average equals=5


HOW TO SOLVE 'C' problem?

1. write a 'c' program to read 4(four)numbers from a file 'BANK' and calculate the average of the numbers.Now print the calculated average in another output file 'AVERAGE' 2. write a 'c' program that finds the sum and average of inputted five integer numbers of the array using dynamic memory allocation function malloc(). 3. write a 'c' program to create simple elements 1,2,3,4 in the link list of 4(four)nodes and display the list's elements. 4. write a 'c' program to convert the expression (A+B)/(C+D) into postfix expression into stack.and then evaluate it for A=10,B=20,C=15,D=5 and display the stack status after each operation. 5. write a 'c' programto create a linked list implemented on an array containing the following numbers:1,2,3,3,3,4,4,9 and pack it to remove the duplicate numbers.so that only the following data are contained by the nodes:1,2,3,4,9


Write a FORTRAN program using if statement to calculate the smallest of three numbers xyz?

N = x If y < N then N = Y If z < N then N = z Print N


How to write a C program to find largest 2 numbers using pointers?

program to find maximum of two numbers using pointers