输入5位数 求位数 正反打印数字(为什么我最高位老是0)

[复制链接]
查看11 | 回复1 | 2008-11-1 20:34:57 | 显示全部楼层 |阅读模式
#include
#include
using namespace std;
int main ()
{
int a[5],b[5];
int i,n,t=0;
cin>>n;
b[0]=n;
for(i=0;i-1;i--)
{
cout us...
回复

使用道具 举报

千问 | 2008-11-1 20:34:57 | 显示全部楼层
太繁琐吧,直接写成下面的#include #include #include using namespace std;int main(){ char num[20]; cin>>num; int j; j=strlen(num); cout<<num<<end...
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行