闫树杰

海阔天空 鸟语花香

study together


Download the theme

#include <stdio.h> 
int numConvert(int,int,int) ; 

int main()
{
intnumber , m , n ;

scanf("%d%d%d",&number,&n,&m);

printf("%d\n",numConvert(number,n,m));
return 0 ;
}
int numConvert(int a,int b,int c){
int x=0,i=1,y=1;
while(a)
{
x+=a%10*i;
a/=10;
i*=b;
}
//下面这部分比较重要  
int p=1,re=0;
while(p*c<=x){
p*=c;
}
while(p)
{
re=x/p+re*10;
x%=p;
p/=c;
}
return re;
}
最近的文章

做一个东西,首先要理清思路,做出原型1.打印棋盘2.可以下棋3.下棋规则明确4.输赢定义数组全局/动态数组清屏 cls stdlib.hwindows.h 移动光标 https://blog.csdn.net/konghouy/article/details/80230571…

继续阅读
更早的文章

今天突然提示我输入ssh密码结果输入哪个密码也不对就尝试了重新配置秘钥结果还是不行提示中显示的还是旧的秘钥后来尝试ssh -T -p 443 git@ssh.github.com结果也不行The authenticity of host '[ssh.github.com]:443 ([20.205.243.160]:443)' can't be established.提示Are you sure you want to continue connecting (yes/no)? 选择...…

继续阅读