This task is to find the number of 'For' loops present in the given cpp program.

[Q]: int a;
int fj(int x, int y);
int main()
{
int n;
cin >> n;
int i;
for (i = 1; i <= n; i++)
{
cin >> a;
cout << fj(a, 2) << endl;
}
return 0;
}
int fj(int x, int y)
{
int xnumber = 1;
int i;
int b = sqrt(x);
if (x == 1) return 0;
else
for (i = y; i <= b; i++)
{
if (x % i == 0) xnumber = xnumber + fj(x / i, i);
}
return xnumber;
}
[A]: 2

[Q]: int qq(int m){
int i,j;
j=0;
for(i=2;i*i<=j;i++){
if(m%i==0){
j=1;
break;
}
}
return j;
}

int pp(int m,int j){
int i,k=0;
if(m==1)
return 1;
else {
k++;
for(i=j;i*i<=m;i++){
if(qq(i)==0&&m%i==0){
k=k+pp(m/i,i);
}
}
}
return k;
}

int main(){
int n,i,p;
cin>>n;
int aa[n+1];
for(i=1;i<=n;i++){
cin>>p;
aa[i]=pp(p,2);
}
for(i=1;i<=n;i++)
cout<<aa[i]<<endl;

return 0;
}
[A]: 4

[Q]: /*
* 1.cpp
*
* Created on: 2010-12-1
* Author: ???
* ??? ????
*/

int g(int x,int j){
for(j++;j<=x;j++){
if(x==j)
return 1;
if(x%j==0&&x/j>=j)
return g(x/j,j-1)+g(x,j);
}
return 0;
}

int main(){
int n,a;
cin>>n;
for(int i=1;i<=n;i++){
cin>>a;
cout<<g(a,1)<<endl;
}
return 0;
}
[A]:
2