mirror of https://github.com/01-edu/public.git
Augusto
5 years ago
committed by
Christopher Fremond
1 changed files with 19 additions and 0 deletions
@ -0,0 +1,19 @@ |
|||||||
|
## strlenprog |
||||||
|
|
||||||
|
### Instructions |
||||||
|
|
||||||
|
- Write a program that counts the characters of a `string` and that returns that value. |
||||||
|
|
||||||
|
- If the program receives more than one `string` or no arguments must not return anything (see the `Expected output`). |
||||||
|
|
||||||
|
### Expected output : |
||||||
|
|
||||||
|
```console |
||||||
|
student@ubuntu:~/piscine-go/strlenprog$ go build |
||||||
|
student@ubuntu:~/piscine-go/strlenprog$ ./strlenprog "hello" |
||||||
|
5 |
||||||
|
student@ubuntu:~/piscine-go/strlenprog$ ./strlenprog |
||||||
|
student@ubuntu:~/piscine-go/strlenprog$ |
||||||
|
student@ubuntu:~/piscine-go/strlenprog$ ./strlenprog "hello" "how are you" |
||||||
|
student@ubuntu:~/piscine-go/strlenprog$ |
||||||
|
``` |
Loading…
Reference in new issue