题解 | #逆序输出#

逆序输出

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

import java.util.Scanner;
public class Main {
    public static void main(String[] args) {
        Scanner sc=new Scanner(System.in);
        int[] array=new int[10];
        for(int i=0;i<10;i++)
        {
            array[i]=sc.nextInt();
        }
        for(int i=0;i<10;i++)
        {
            System.out.print(array[9-i]+" ");
        }
    }
}

全部评论

相关推荐

不愿透露姓名的神秘牛友
07-10 13:54
点赞 评论 收藏
分享
点赞 评论 收藏
分享
评论
1
收藏
分享

创作者周榜

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