Is there an elegant way to create and initialize a const std::vector like const T a[] = { ... } to a fixed (and small) number of val
const std::vector
const T a[] = { ... }
You either have to wait for C++0x or use something like Boost.Assign to do that.
e.g.:
#include using namespace boost::assign; // bring 'operator+=()' into scope vector v; v += 1,2,3,4,5;
for C++11:
vector luggage_combo = { 1, 2, 3, 4, 5 };