/*
将一个数组逆序输出。
*/
class MainClass
{
public static void main(String[] args) throws Exception
{
int[] arr = {1, 2, 3, 4, 5, 6, 7, 8, 9};
for(int i = arr.length - 1; i >= 0; i--)
{
System.out.print(arr[i] + "\t");
}
System.out.println("");
}
}
/*
*/
java50题----31数组逆序输出
最新推荐文章于 2021-07-21 10:43:12 发布