And just to satisfy your demands here is function that takes a reference to any size array ![]()
template< typename T, size_t N > void Foo( T (&t)[N] ){
Serial.write( t, N );
}
And the pointer version
template< typename T, size_t N > void Foo( T (*t)[N] ){
Serial.write( *t, N );
}
And if you look closely there is no need for sizeof to get the length.