arraycopy

Why is System.arraycopy native in Java?

I was surprised to see in the Java source that System.arraycopy is a native method. Of course the reason is because it's faster. But what native tricks is the code able to employ that make it faster? Why not just loop over the original array and copy each pointer to the new array - surely this isn't that slow and cumbersome? ...

Java : Resizing a multidimensional array.

I have a multidimensional array built from Strings that is initially created with the size [50][50], this is too big and now the array is full of null values, I am currently trying to remove these said null values, I have managed to resize the array to [requiredSize][50] but cannot shrink it any further, could anyone help me with this? I...