题解 | #数字颠倒#

数字颠倒

http://www.nowcoder.com/practice/ae809795fca34687a48b172186e3dafe

import java.util.*;

public class Main{
    public static void toOut(int num){
        List<Integer> intNum = new ArrayList<>();
        while(num>0){
            intNum.add((num%10));
            num /= 10;
        }
        for(int data:intNum){
            System.out.print(data);
        }
    }
    public static void main(String[] args){
        Scanner in = new Scanner(System.in);
        int num = in.nextInt();
        toOut(num);
    }
}
全部评论

相关推荐

10-16 23:37
已编辑
门头沟学院 运营
据说名字越长别人越关...:西交做运营吗。。就业市场已经颠了
简历被挂麻了,求建议
点赞 评论 收藏
分享
10-19 00:57
门头沟学院 Java
我不是嘉心糖捏:我刚收到面试捏
投递360集团等公司6个岗位
点赞 评论 收藏
分享
评论
点赞
收藏
分享

创作者周榜

更多
牛客网
牛客网在线编程
牛客网题解
牛客企业服务