#include <iostream>
#include <type_traits>

template<typename T, T b, T e>
struct constexpr_pow : std::integral_constant<T, b*constexpr_pow<T, b, e-1>::value>
{
};
template<typename T, T b>
struct constexpr_pow<T, b, 1> : std::integral_constant<T, b>
{
};

int main()
{
	std::cout << constexpr_pow<unsigned, 2, 8>::value << std::endl;
}
