R, 190 178 175 Bytes
Mungkin masih ada ruang untuk bermain golf di sini. Mungkin beberapa operasi yang tidak perlu di sana
l=lapply;s=substring;C=rbind;d=do.call;cat(C(d(C,l(apply(d(C,l(a<-scan(,''),s,1:(w=max(nchar(a))),1:w))[(h=length(a)):1,],2,paste0,collapse=''),s,1:h,1:h))[,h:1],'\n'),sep='')
Tidak diikat dan dijelaskan
a<-scan(,'') # get STDIN
h<-length(a) # number of lines
w=max(nchar(a)) # length of longest line
M<-lapply(a,substring,1:w,1:w) # create a list of split strings with empty chars
M<-do.call(rbind,M)[h:1,] # turn it into a matrix with line order reversed
M<-apply(M,1,paste0,collapse='') # paste together the columns
M<-lapply(M,substring,1:h,1:h) # split them back up
M<-do.call(rbind,M)[,h:1] # reform a matrix
M<-rbind(M,'\n') # add some carriage returns
cat(M,sep='') # output with seperators
Uji Coba. Sangat menarik untuk dicatat bahwa karena cara pemindaian bekerja, seluruh kalimat dapat dimasukkan dengan spasi dan masih memberikan output seperti yang ditentukan.
> l=lapply;s=substring;C=rbind;d=do.call;cat(C(d(C,l(apply(d(C,l(a<-scan(,''),s,1:(w=max(nchar(a))),1:w))[(h=length(a)):1,],2,paste0,collapse=''),s,1:h,1:h))[,h:1],'\n'),sep='')
1: Programming
2: Puzzles
3: &
4: Code
5: Golf
6:
Read 5 items
P
Prog
&uzz
Coderam
Golflesming
> l=lapply;s=substring;C=rbind;d=do.call;cat(C(d(C,l(apply(d(C,l(a<-scan(,''),s,1:(w=max(nchar(a))),1:w))[(h=length(a)):1,],2,paste0,collapse=''),s,1:h,1:h))[,h:1],'\n'),sep='')
1: Programming Puzzles & Code Golf beta
7:
Read 6 items
P
Prog
&uzz
Code
Golfram
betalesming
>