Encoder decoder by tabasa

f=(gets[0,1]=='e')\x0d
gets(p)\x0d
w=[]\x0d
d=$_.chomp\x0d
if f\x0d
w<<d[-1,1]\x0d
d[-1,1]=""\x0d
while(d.size>0)\x0d
w.unshift(d[-2,1])\x0d
w<<d[-1,1]\x0d
d[-2,2]=""\x0d
end\x0d
else\x0d
w<<d[0,1]\x0d
d[0,1]=""\x0d
while(d.size>0)\x0d
w<<d[-1,1]\x0d
w<<d[0,1]\x0d
d[-1,1]=""\x0d
d[0,1]=""\x0d
end\x0d
end\x0d
puts w.join

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

download

return to the top page