#include<bits/stdc++.h>
using namespace std;
int a[100001];
void yinzi(int m,int t)
{
int b=0;
if(m<t||m==1)
return;
else
{
while(m%t==0)
{
m=m/t;
a[t]++;
b=1;
}
if(a[t]>1)
cout<<t<<"^"<<a[t];
else if(a[t]==1)
cout<<t;
if(m>t&&b==1)
cout<<"*";
y(m,t+1);
}
}
int main()
{
int n,i=2;
scanf("%d",&n);
y(n,i);
return 0;
}
因子分解
最新推荐文章于 2026-01-05 22:36:07 发布
1515

被折叠的 条评论
为什么被折叠?



