Browse Source

fix of comcheck

content-update
Christopher Fremond 5 years ago committed by Christopher Fremond
parent
commit
9346ce9918
  1. 8
      subjects/comcheck.en.md
  2. 37
      subjects/comcheck.fr.md

8
subjects/comcheck.en.md

@ -2,11 +2,13 @@
### Instructions
Write a program `comcheck` that displays on the standard output `Alert!!!` followed by `\n`.
Write a program `comcheck` that displays on the standard output `Alert!!!` followed by newline(`'\n'`) if at least one of the arguments passed in parameter matches the `strings`:
- If one of the arguments passed in parameter corresponds to the words `01`, `galaxy`, `galaxy 01`.
- `01`, `galaxy` or `galaxy 01`.
Examples of outputs :
- If none of the parameters match, the program displays a newline(`'\n'`).
### Usage
```console
student@ubuntu:~/piscine/comcheck$ go build

37
subjects/comcheck.fr.md

@ -1,44 +1,15 @@
## ROT 14
## comcheck
### Instructions
Write a function `rot14` that returns the string within the parameter but transformed into a rot14 string.
écrire un programme `comcheck` qui affiche sur la sortie standard `Alert!!!` suivi d'un newline(`'\n'`) si au moins un des arguments passé ne paramètre correspond aux `strings`:
- If you not certain what we are talking about, there is a rot13 already.
- `01`, `galaxy` ou `galaxy 01`.
### Expected function
```go
func rot14(str string) string {
}
```
- If none of the parameters match, the program displays a newline(`'\n'`).
### Usage
Here is a possible [program](TODO-LINK) to test your function :
```go
package main
import (
"github.com/01-edu/z01"
)
func main() {
result := rot14("Hello How are You")
arrayRune := []rune(result)
for _, s := range arrayRune {
z01.PrintRune(s)
}
z01.PrintRune('\n')
}
```
And its output :
```console
student@ubuntu:~/piscine/comcheck$ go build
student@ubuntu:~/piscine/comcheck$ ./comcheck "I" "Will" "Enter" "the" "galaxy"

Loading…
Cancel
Save