STRING by eban

$<.map{s=gets.chop
a=gets.to_i
puts a>0? s*a:s.reverse*-a}

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

download

return to the top page