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

Q: int sum=0,used[32770]={0};//????sum???????????used?i???i????????
void f(int n)//??f??n????????
{
	for(int i=2;i<=n;i++)
	{
		if(n%i==0&&used[i]==0)
		{
			if(i!=2)
			{
				for(int j=2;j<=i-1;j++)
					used[j]=1;
			}
			if(n/i==1)//??????????
			{
				sum++;
				break;
			}
			else
			{
				f(n/i);
			}
			memset(used,0,sizeof(used));//?used???????
		}
	}
}
int main()
{
	int m,a[100];
	cin>>m;
	for(int i=1;i<=m;i++)
	{
		cin>>a[i];
		if(a[i]==1)
			cout<<1<<endl;
		else
		{
			f(a[i]);
			cout<<sum<<endl;
			sum=0;//??
			memset(used,0,sizeof(used));
		}
	}
	return 0;
}

A: 3
****
Q: int num=0;
void count(int m,int j)
{
	int i;
	if(m==1) num++;
	for(i=j;i<=m;i++)
	{
		if(m%i==0) {count(m/i,i);}
		else continue;}
}
int main()
{
	int n,i;
	cin>>n;
	for(i=1;i<=n;i++)
	{
		int m;
		cin>>m;
		num=0;
		count(m,2);
		cout<<num<<endl;
	}
	return 0;
}


A: 2
****
Q: int sum=0,t;          //sum?????????,t??????
void dg(int s)        //?s????
{
	for(int i=s;i<=t;i++)
	{
		if(t%i==0)   //?i??t??
		{
			t=t/i;
			if(t==1) sum++;   //t????,??+1
			else dg(i);       //??????
			t=t*i;
		}
	}
}
int main()
{
	int n;
	cin>>n;
	while(n--)       //??n?
	{
		cin>>t;
		dg(2);
		cout<<sum<<endl;
		sum=0;
	}
	return 0;
}

A:
1
****
