#include <cstddef>
#include <array>

template< std::size_t ... >
struct index_helper {};

template< std::size_t n, std::size_t ... seq >
struct index_helper< n, seq ... >
    { typedef typename index_helper< n - 1, n, seq ... >::type type; };

template< std::size_t ... seq >
struct index_helper< 0, seq ... >
    { typedef index_helper type; };

template< std::size_t size >
constexpr std::array< char, size >
string_to_array( char const (&str)[ size ] )
    { return string_to_array( str, typename index_helper< size - 2 >::type() ); }

template< std::size_t size, std::size_t ... index >
constexpr std::array< char, size >
string_to_array( char const (&str)[ size ],
                 index_helper< index ... > )
    { return {{ str[ ( index + 3 ) % size ] ... }}; }

constexpr std::array< char, 14 > x = string_to_array( "hello, world!" );

#include <iostream>

int main() {
    std::cout.write( x.begin(), x.size() );
}