Elemen pertama dan terakhir dari array java

int[] a = new int[]{1, 8, 5, 9, 4};

First Element: a[0]

Last Element: a[a.length-1]
Beautiful Bug