Question #10341

c program that generate all even numbers between 1 and 100 and sum two fractions

Expert's answer

#include "stdafx.h"
#include <iostream>

using namespace std;
int _tmain(int argc, _TCHAR* argv[])
{
int sum=0;
cout<<"Even numbers:";
for(int i=1;i<=100;i++){
if(i%2==0){
cout<<i<<" ";
}

sum+=i;
}

cout<<"
Sum of two fractions is "<<sum/2;
int k;
cin>>k;
return 0;
}

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

LATEST TUTORIALS
APPROVED BY CLIENTS