forked from root/public
Compare commits
2 Commits
master
...
1139-rev-a
Author | SHA1 | Date |
---|---|---|
Hamza elkhatri | 236084b9ab | 2 years ago |
hamza | 9d1465f391 | 2 years ago |
1 changed files with 19 additions and 0 deletions
@ -0,0 +1,19 @@
|
||||
### rev-arg |
||||
|
||||
### Instructions |
||||
|
||||
Write a program that takes the command line arguments and prints them in reverse order. |
||||
- if the number of arguments is less than 1, print (`'\n'`) |
||||
|
||||
### Usage |
||||
|
||||
```console |
||||
$ go run . | cat -e |
||||
$ |
||||
$ go run . "Hello World!" | cat -e |
||||
Hello World!$ |
||||
$ go run . "Hello World!" "World!" "All" | cat -e |
||||
All World! Hello World!$ |
||||
$ go run . 1 2 3 4 | cat -e |
||||
4 3 2 1$ |
||||
``` |
Loading…
Reference in new issue