BEGIN{RS=RSRS}{for(i=-1;++i<n=(NF/2)^.5;)for(j=0;j++<n;printf(n>j?s FS:s"\n"))for(s=k=0;k<n;)s+=$(j+n+2*n*k++)*$(k+2*n*i);$0=x}1

Note that non-ascii characters in the above source code will be escaped (such as \x9f).

download

return to the top page