public class Test15 {
public static void main(String[] args) {
int[] a = {1,3,5,4};
int temp = 0;
for(int i = a.length - 1; i > a.length / 2; i--) {
System.out.println(a[i]);
}
}
}
//输入:4 5 3 1
将数组元素倒序排列
最新推荐文章于 2021-03-15 08:15:52 发布