medium of two array of same size