1. Write C++ program to find the sum of two numbers.
Share
1. Write C++ program to find the sum of two numbers.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Answer:
notes chapter = C++ graphics
Explanation:
Answer:
int main()
{
int x,y;
int total = 0;
cout<<"Please give me an integer: ";
cin >> x;
cout<<"Please give me another integer: ";
cin >> y;
int counter = x;
while(counter <= y ){
total += counter;
++counter;
}
cout << "The total of the numbers " << total<<endl;
}