Write a program that will display all numbers multiple of 7 which are between 1 and 100 and display the cumulative sum as well as the final sum. solve with do while
1
Expert's answer
2020-01-03T09:36:00-0500
#include <iostream>
using namespace std;
void main()
{
int i=1;
int sum =0;
do{
if (i%7==0)
{
cout <<i << “ ”;
sum+=i;
}
i++;
}while(i<100);
cout <<endl <<“sum =”<<sum;
}
Numbers and figures are an essential part of our world, necessary for almost everything we do every day. As important…
APPROVED BY CLIENTS
Finding a professional expert in "partial differential equations" in the advanced level is difficult.
You can find this expert in "Assignmentexpert.com" with confidence.
Exceptional experts! I appreciate your help. God bless you!
Comments
Leave a comment