I know that if you want to pass an array by reference with a known size you use
void add(char (&arr)[60])
But i only know that the array will be size between 1 and 60 inclusive. Any way to do this?
I know that if you want to pass an array by reference with a known size you use
void add(char (&arr)[60])
But i only know that the array will be size between 1 and 60 inclusive. Any way to do this?
other option , without using templates :
void add(char* arr , int size);
Remember that ad-hoc array names are "decaying" to be a pointer to the first element , so one-dimensional array can be passes as a pointer.