I have no idea what it's supposed to do, but is doesn't initialise anything.
By the time the array is passed to the function, the array would have been fully initialised. The function actually assigns new values to the array. So effectively, you're just replacing the existing values with new ones.