求助大佬debug(头文件都有,格式不合格删掉了)
查看原帖
求助大佬debug(头文件都有,格式不合格删掉了)
613337
Theadora楼主2021/11/18 18:34
int M,N,i;
cin>>M>>N;
int a[10000]; 
for(i=0;N!=0;i++)
{
	a[i]=N%10;
	N/=10;
}
int count=i-1;
for(int j=i-1;j>=0;j--)
{
	if(a[j]==0)
	{
	    count--;			
		continue;
	}
	cout<<a[j]<<"*"<<M<<"^"<<count;
    count--;
	if(j>0)
	{
		cout<<"+";
	}
}
return 0;}
2021/11/18 18:34
加载中...