请编写方法int[]invertArray(int[]a),该方法返回一个数组b,b中元素顺序为数组a 中元素的逆序。 int[] invertArray(int []a){ //请在答题卡(纸)上填写此处应编写的代码 }
int[]b=new int[a.length];For(int i=0;i
请编写方法int[]invertArray(int[]a),该方法返回一个数组b,b中元素顺序为数组a 中元素的逆序。 int[] invertArray(int []a){ //请在答题卡(纸)上填写此处应编写的代码 }
int[]b=new int[a.length];For(int i=0;i