Program to find the sum of elements in a given array | faceprep

Program to find the sum of elements in a given array | faceprep

The program to find the sum of elements in a given array is discussed here.

Program to find the sum of elements of an array


Given the number of elements of the array and the array elements, the sum of the elements of the array is produced as output.

Input Format:

  • Input the number of elements of the array
  • Input the Array elements

Input :

3

1

2

3

Output :

6


program to find the sum of elements in a given arrayClick here to learn more about FACE Prep PRO


Algorithm to find the sum of elements in a given array

  • Input the number of elements of the array.
  • Input the array elements.
  • Sum = addition of all the array elements.
  • Display sum.


Program to find the sum of elements in a given array

@@coding::1@@


Recommended Programs



Program to find the array type (even, odd or mixed array)