public class Test { public static void main(String[] args) { int[] i = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10}; for(int j=0; j System.out.print(i[j] + " "); } for(int j=i.length-1; j>=0; --j) { System.out.print(i[j] + " "); } }}
什么叫顺序和逆序输出20的JAVA程序啊,你是要排序吗?还是干什么