Why is the finally statement needed if there is no catch block? (Java) : My teacher was explaining how the `finally` statement is optional in a `try-catch` blockbut why is it absolutely necessary if there is no `catch` statement?

For example:

    try{
			for(int j = 0; j <= i.length; j++)
			{
				System.out.println(i[j]);
			}
		}
		catch(ArrayIndexOutOfBoundsException e)
		{
			System.out.println("Catch");
		}//no errors

    try{
			for(int j = 0; j <= i.length; j++)
			{
				System.out.println(i[j]);
			}
		}//syntax error

Error code:

    Exception in thread "main" java.lang.Error: Unresolved compilation problem: 
	Syntax error, insert "Finally" to complete TryStatement

	at Driver.main(Driver.java:12)