First implementation of assign() and copy() method for all arrays (though not fully optimized).