60 693
Assignments Done
97,9%
Successfully Done
In April 2018

Answer to Question #5561 in C++ for Jimmy

Question #5561
write a c++ program to print all the pelindrom number between 1 and 100 using do while do
Expert's answer
#include <cstdlib>
#include <iostream>

using namespace std;

int main(int argc, char *argv[])
{
int i=8,a[100];
cout<<"1 2 3 5 7 ";
do
{
& a[i]=i;
& if (a[i]%2!=0 && a[i]%3!=0 && a[i]%5!=0 && a[i]%7!=0) cout<<a[i]<<" ";
& i++;
}
while (i<=100);
system("PAUSE");
return EXIT_SUCCESS;
}

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!

Comments

No comments. Be first!

Leave a comment

Ask Your question

Submit
Privacy policy Terms and Conditions