Q:

The multiplication of even numbers in c++

belongs to collection: All you need to know about C++

0

Write a program to calculate the product of multiplication all even numbers from 2 to 10

All Answers

need an explanation for this answer? contact us directly to get an explanation for this answer

#include<iostream.h>
void main ()
{
int i,product;
product=1;
i=2;
do
{
product*=i;
i+=2;
}
while(i<=10);
cout<<"product="<<product;
}
}

need an explanation for this answer? contact us directly to get an explanation for this answer

total answers (1)

This question belongs to these collections

Similar questions


need a help?


find thousands of online teachers now
<< The arithmetic operation in language c++...