Shell command to modify each line of a file

I have a test.txt file with the following text

1 2 3 4
3 4 5 6
8 7 3 2

I want to save it as

4 3 2 1
6 5 4 3
2 3 7 8

Is there any shell command that does this?

+4
source share
1 answer

rev will complete the task:

rev file
4 3 2 1
6 5 4 3
2 3 7 8
+8
source

Source: https://habr.com/ru/post/1598166/


All Articles