Write program to add 5 numbers using loop instructions
Answers
Answered by
0
In C++
#include
using namespace std;
int main()
{
int num,sum=0;
for(int I=0;I<5;I++)
{
cin>>num;
sum+=num;
}
count<return 0;
}
#include
using namespace std;
int main()
{
int num,sum=0;
for(int I=0;I<5;I++)
{
cin>>num;
sum+=num;
}
count<return 0;
}
Similar questions