-1

Is there a way to show data in a file in reverse order ? input file is:

string1
string2
string3

i would like it to be

string3
string2
string1

*don't want the data to be sorted.

Ziv Attia
  • 57
  • 7

1 Answers1

1

That's exactly what tac does.

tac - concatenate and print files in reverse

Just do

tac file
oguz ismail
  • 1
  • 16
  • 47
  • 69