Given an array type, you can get the size of the array with array_size.
The code fragment array_size<type>::value will only compile if type is an array. It won't compile if type is a union, struct or class.
typedef int Array[10]; size_t n = array_size<Array>::value; n has the value of 10.