Zadatak13-15

#include <iostream>

using namespace std;

int main()
{
int br,n;

cin>>n;
for (int i=n-1;i>1;i–)
{ br=0;
for (int j=1;j<=i;j++)
{ if (i%j==0) br=br+1; }
if (n%i==0 && br<3)
cout<<i<<“ „; }
return 0;
}

Advertisements