I wrote a factoring program and i am getting factors plus other numbers back im not sure why i have tried using differen't loops and changing the order of the operations. help please not sure what i need to change.
[code]
#include <iostream>
#include <iomanip>
using namespace std;
int main(void)
{
int num,
factor = 2,
counter = 0;
cout << "Please Enter a Positive Number: " << endl;
cin >> num;