I was wondering if its possible to make the following answer more generic, in the sense that the type of the array be templated instead of just unsigned:
I\'ve enclosed
Erm... Why don't you just use std::vector? Or if you want a non-resiable array, then use the equivalent type in boost?