Questions tagged [tac]
The tac tag has no summary.
6 questions
4 votes
2 answers
1k views
tac-command is it a bug or a misinterpretation of the manual?
I needed to reverse the order of blank-separated words. GNU tac comes to mind and has an -s-option which lets you set the separator: -s, --separator=STRING use STRING as the separator ...
5 votes
4 answers
2k views
Reversing a file line-wise and character-wise
Input: hello enrico output: ocirne olleh To do this, I can simply tac a file and pipe the output to rev (or the other way around), so one function that does the job is just this: revtac() { tac &...
1 vote
1 answer
319 views
Usage of readarray and tac
I have a file containing "lines" of text, for now only two lines. I need to create a reversed array of these lines - FIFO style. Using "readarray" in this fashion works fine: readarray -t FileArray &...