#include <iostream>\x0d int main()\x0d {\x0d std::string w;\x0d std::cin >> w;\x0d short i;\x0d for(i=0; w[i]!=0; ++i)\x0d if(i%2)\x0d w.insert(i,1,' '); \x0d short k=w.size()/2;\x0d short j=0;\x0d for(i=w.size()-1; i>=0; i-=2, --k,j+=2){\x0d std::string p(w.size(), ' ');\x0d p.replace(i-k,1+j , &w[i]);\x0d std::cout << p << "\n"; \x0d }\x0d }\x0d
Note that non-ascii characters in the above source code will be escaped (such as \x9f).