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

Ex Input:
/**
 * author:liucheng
 * date:2010-10-23 13:04:16
 * file:factors.cpp
 */

int factor(int num,int minA1)
{
        int count=0;
        int sqrtNum;
        int i;

        if(num <= minA1)
                return 0;

        sqrtNum=(int)sqrt((double)num);
        for(i=minA1;i<=sqrtNum;i++)
                if(num % i == 0)
                {
                        count++;//num=i*(num/i)
                        count+=factor(num/i,i);//num=i*(factor(num/i))
                }

        return count;
}


int main()
{
        int n;
        int num;

        cin>>n;

        while(n -- )
        {
                cin>>num;
                cout<<factor(num,2)+1<<endl;
        }

        return 0;
}

Ex Output:
1


Ex Input:
int main(){
	int number(int n, int low);
	int n, i, data, ans;
	scanf("%d", &n);
	for (i=1; i<=n; i++)
	{
		scanf("%d", &data);
		ans = number(data, 2);
		printf("%d\n", ans);
	}
}
int number(int n, int low)
{
	int j, ans;
	ans = 0;
	for (j = low ; j * j<= n; j++)
	{
		if (n % j == 0) 
			ans = ans + number(n / j, j);
	}
	ans = ans + 1;
	return ans;
}

Ex Output:
2


Ex Input:
int i,n,k;

int work(int p,int n)
{
	if (n==1) k++;
	for (int i=p;i<=n;i++)
		if (n%i==0) work(i,n/i);
}
int main()
{
	int m;
	cin>>m;
	while (m>0)
		{
     cin>>n;
     k=0;
     work(2,n);
					cout<<k<<endl;
					m--;
		}
	return 0;
}


Ex Output:

1


