怎样用c语言表示 翻转的数 比如把81 翻转为18

日期:2021-07-09 14:09:57 人气:1

怎样用c语言表示 翻转的数 比如把81 翻转为18

用c语言表示翻转的数可以参考下面的代码:

#include <stdio.h>

int main()

{int C,D,S;

scanf("%d",&C);

D=(C%10)*10+C/10;

S=C+D;

printf("S=%d",S);

}

热门评论