标签:des style http color io os ar java for
7 2 23 12 -4 3
111 1B -11
<pre name="code" class="cpp">#include <stdio.h> #include <stdlib.h> #include <string.h> int main() { int number; int n; while(scanf("%d %d",&number,&n)!=EOF) { bool flag=false; if(number<0){ number=-number; flag=true; } char str[10]; itoa(number,str,n); int len = strlen(str); for(int i=0;i<len;i++) if(str[i]>='a'&&str[i]<='z') str[i]-=32; if(flag) printf("-%s\n",str); else printf("%s\n",str); } return 0; }
标签:des style http color io os ar java for
原文地址:http://blog.csdn.net/zhuangjingyang/article/details/40209855