i have this code :
import java.util.Scanner;
public class lectureArray {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
System.out.print("Enter a number: ");
int n = sc.nextInt();
int [] arr = new int[n];
for(int i = 0; i < n; i++)
arr[i] = sc.nextInt();
for(int i = n-1; i >= 0; i--);
System.out.println(arr[i] ) ;
}
}
and i have this error: "i cannot be resolved to a variable" . no matter how much i tried to get rid of it, it just making more errors or not resolving the error in the first place