i want to make a prgoram that will read in a set of numbers and determine whether or not they are prime numbers, this is what i got so far any ideas?
#include <iostream>
#include <queue>
#include <vector>
using namespace std;
int main()
{
queue <int> input;
queue <int> prime;
int inputNum;
int temp;
cout << "Type the numbers, ending with 0: " << endl;
while(!inputNum == 0)
{
cin >> inputNum;
if (!inputNum == 0)
{
input.push(inputNum);
}
}
while(!input.empty())
{
temp = input.front();
for (int i = 2; i <= 9; i++)
{
if (input.front() % i != 0)
{
prime.push(temp);
cout << prime.size();
}
}
input.pop();
}
while(!prime.empty())
{
cout << prime.front() << endl;
prime.pop();
}
system ("pause");
return 0;
}