template<unsigned int...>
struct IndexList{
};

template<class IndexList, unsigned int LAST> struct Append;

template<unsigned int... FIRST, unsigned int LAST>
struct Append<IndexList<FIRST...>, LAST> {
  typedef IndexList<FIRST..., LAST> Result;
};

template<unsigned int N>
struct Indices {
  typedef typename Append<typename Indices<N - 1U>::Result, N - 1U>::Result Result;
};

template<>
struct Indices<0U> {
  typedef IndexList<> Result;
};

template<unsigned int N>
struct PowerOfTen {
  static_assert(N < 20U, "Too large");
  static const unsigned long long value = 10ULL * PowerOfTen<N - 1>::value;
};

template<>
struct PowerOfTen<0U> {
  static const unsigned long long value = 1ULL;
};

template<class IndexList> struct Values;

template<unsigned int... N>
struct Values<IndexList<N...>> {
  static const unsigned long long values[sizeof...(N)];
};

template<unsigned int... N>
const unsigned long long Values<IndexList<N...>>::values[sizeof...(N)] = {
  PowerOfTen<N>::value...
};

template<unsigned int N>
using PowerOfTenTable = Values<typename Indices<N>::Result>;

#include <iostream>

int main() {
  for (unsigned int i = 0; i < 10U; ++i) {
    std::cout << PowerOfTenTable<10U>::values[i] << std::endl;
  }
  return 0;
}