From 9346ce9918ac3d71aa7ffab32abb0b57a6039f8a Mon Sep 17 00:00:00 2001 From: Christopher Fremond Date: Fri, 21 Jun 2019 17:10:18 +0100 Subject: [PATCH] fix of comcheck --- subjects/comcheck.en.md | 8 +++++--- subjects/comcheck.fr.md | 37 ++++--------------------------------- 2 files changed, 9 insertions(+), 36 deletions(-) diff --git a/subjects/comcheck.en.md b/subjects/comcheck.en.md index c0649905..17b6674d 100644 --- a/subjects/comcheck.en.md +++ b/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 diff --git a/subjects/comcheck.fr.md b/subjects/comcheck.fr.md index cbd69d91..79493d8e 100644 --- a/subjects/comcheck.fr.md +++ b/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"