public static void main(String[] args) {
int[] arr = new int[5];
arr[0] = 1;
arr[1] = 2;
arr[2] = 3;
arr[3] = 4;
arr[4] = 5;
//int[] arr = {11,22,33,44,55};
int print = biao(arr);
System.out.println(print);
}
public static int biao(int[] arr) {
for (int i = 0;i < arr.length ;i++ ) {
//System.out.print(arr[i] + " ");
return arr[i];
}
return -1;
|
|