mirror of https://github.com/01-edu/public.git
Mohamed Zaboub
2 years ago
committed by
José Rosendo
1 changed files with 21 additions and 0 deletions
@ -0,0 +1,21 @@ |
|||||||
|
## replaceeven |
||||||
|
|
||||||
|
### Instructions |
||||||
|
|
||||||
|
Write a program that takes every character with an even index, of each argument and replace it with the number 2. |
||||||
|
|
||||||
|
- you program should always print `\n` at the end. |
||||||
|
- you program should print all the arguments in one line, separated by the space character `' '`. |
||||||
|
- zero is an even number. |
||||||
|
|
||||||
|
|
||||||
|
### Usage |
||||||
|
|
||||||
|
```sh |
||||||
|
$ go run . | cat -e |
||||||
|
$ |
||||||
|
$ go run . hello 444444444444444 | cat -e |
||||||
|
2e2l2 242424242424242$ |
||||||
|
$ go run main.go "Zone 01 is the best" | cat -e |
||||||
|
2o2e202 2s2t2e2b2s2$ |
||||||
|
``` |
Loading…
Reference in new issue