Răspuns:
#include <iostream>
using namespace std;
int main()
{unsigned int a,d=1,nr=0,ogl=0;
cin>>a;
while (a>=d)
{if (a%d==0)
nr=nr+1;
d=d+1;}
if (nr!=2)
cout<<"Nu";
else
{d=1;nr=0;
while (a>0)
{ogl=ogl*10+a%10;
a=a/10;}
while (ogl>=d)
{if (ogl%d==0)
nr=nr+1;
d=d+1;}
if (nr!=2)
cout<<"Nu";
else
cout<<"Da";}
return 0;
}