parameter
Hey, For example I have the following code. public class SpecialArray { // fibonacci public static boolean isFibonacciArray(int arr[]) { for (int i = 2; i < arr.length; i++) if (arr[i] != arr[i - 1] + arr[i - 2]) return false; return true; } public static void main(String[] args) { int array[] = { 0, 1, 1, 2, 3, 5, 8, 13, 21 }; boolean isFibonacci = isFibonacciArray(array); if (isFibonacci == true) System.out.println("Fibonnaci"); else System.out.println("NOT fibonnaci"); } } I want to know if inside the Main I have, for example, the variable int[] array, if I call the function then the array goes into the parameter which is int[] arr in the boolean function and then everything that is actually related to the int[] arr becomes the int[] array I have in the main? Which means that in fact the int[] arr found in the for loop and also inside the if becomes an int[] array of the main function? Thanks for help!