View the Most Wanted LQ Wiki articles.
LinuxQuestions.org > Linux Wiki > Rev

From LQWiki

Jump to: navigation, search

rev is the same as cat, only rev shows characters in reverse. Imagine a file foo that contains:

hello
world

rev foo will print:

olleh
dlrow

to print lines in reverse you can use tac, to print both lines and characters in reverse, for example, use:

tac foo | rev

Personal tools