Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


create a c++ program that will ask 10 numbers and display
their sum using array.



create a c++ program that will ask 10 numbers and display their sum using array. ..

Answer / sneha shahade

#include<conio.h>
#include<iostream.h>
void main()
{
int a[10],i,s=0;
cout<<"enter 10 numbers";
for(i=0;i<10;i++)//loop to get 10 no. in array
cin>>a[i];
for(i=0;i<10;i++)//loop to find sum of 10 no.
s=s+a[i];
cout<<"sum is:"<<s;//display sum
getch();
}

Is This Answer Correct ?    9 Yes 0 No

Post New Answer

More OOPS Interview Questions

There are two base class B1,B2 and there is one class D which is derived from both classes, Explain the flow of calling constructors and destructors when an object of derived class is instantiated.

0 Answers  


how to find the largest of given numbers in an array

2 Answers  


can you explain how to use JavaBean in Project

3 Answers   Infosys, Satyam,


What is polymorphism what are the different types of polymorphism?

0 Answers  


Why many objects can working together? How objects working togetherM I want to see example code.

2 Answers  


can you give the dynamic polymorphism types?

2 Answers   Wipro,


What is an interface in oop?

0 Answers  


What is Method overloading?

5 Answers  


explain dynamic binding by drowing

2 Answers   Cognizant,


What is encapsulation in oops?

0 Answers  


What is difference between oop and pop?

0 Answers  


In what situation factory design patterns,DAO design patterns,singleton design patterns should be applied.?

2 Answers  


Categories