#! /bin/sed -f

# Reverse a line; add a new-line to the end
s/$/\
/

# Move first character at the end.  The regexp matches
# until the first character has become the new-line
t x
:x
s/\(.\)\(.*\n\)\(.*\)/\2\1\3/
t x

# Remove the new-line
s/^.//

### colorized by sedsed, a SED script debugger/indenter/tokenizer/HTMLizer
### original script: http://sed.sf.net/grabbag/scripts/revchr_1.sed