What is the proper method for modifying char array?

I've changed the function declaration to this

void getSerialNumber(char num[(UniqueIDsize*2)+1]){ and the same for the global variable, that's a great idea so it works on any board. Second question was basically asking if this is like luck that it works this way because it's a char array will a null terminated character or if I used it with any array it would work the same. I'm going to look up passing by reference now