Browse Source

translations of quest10 finished

content-update
Christopher Fremond 5 years ago
parent
commit
ef668dfdc7
  1. 2
      subjects/activebits.en.md
  2. 10
      subjects/activebits.fr.md
  3. 4
      subjects/max.en.md
  4. 12
      subjects/max.fr.md
  5. 4
      subjects/unmatch.en.md
  6. 12
      subjects/unmatch.fr.md

2
subjects/activebits.en.md

@ -2,7 +2,7 @@
### Instructions ### Instructions
Write a function, `ActiveBits`, that returns the number of active bits (bits with the value 1) in the binary representation of an integer number. Write a function, `ActiveBits`, that returns the number of active `bits` (bits with the value 1) in the binary representation of an integer number.
### Expected function ### Expected function

10
subjects/activebits.fr.md

@ -2,9 +2,9 @@
### Instructions ### Instructions
Write a function, `ActiveBits`, that returns the number of active bits (bits with the value 1) in the binary representation of an integer number. Écrire une fonction, `ActiveBits`, qui retourne le nombre de `bits` actifs (`bits` ayant la valeur 1) dans la représentation binaire d'un nombre entier.
### Expected function ### Fonction attendue
```go ```go
func ActiveBits(n int) uint { func ActiveBits(n int) uint {
@ -12,9 +12,9 @@ func ActiveBits(n int) uint {
} }
``` ```
### Usage ### Utilisation
Here is a possible [program](TODO-LINK) to test your function : Voici un éventuel [programme](TODO-LINK) pour tester votre fonction :
```go ```go
package main package main
@ -30,7 +30,7 @@ func main() {
} }
``` ```
And its output : Et son résultat :
```console ```console
student@ubuntu:~/piscine/test$ go build student@ubuntu:~/piscine/test$ go build

4
subjects/max.en.md

@ -2,9 +2,7 @@
### Instructions ### Instructions
Write a function, Max, that returns the maximum value in a slice of integers Write a function, `Max`, that returns the maximum value in a slice of integers.
The function must have the next signature.
### Expected function ### Expected function

12
subjects/max.fr.md

@ -2,11 +2,9 @@
### Instructions ### Instructions
Write a function, Max, that returns the maximum value in a slice of integers Écrire une fonction, `Max`, qui retourne la valeur maximum dans une slice d'entiers.
The function must have the next signature. ### Fonction attendue
### Expected function
```go ```go
func Max(arr []int) int { func Max(arr []int) int {
@ -14,9 +12,9 @@ func Max(arr []int) int {
} }
``` ```
### Usage ### Utilisation
Here is a possible [program](TODO-LINK) to test your function : Voici un éventuel [programme](TODO-LINK) pour tester votre fonction :
```go ```go
package main package main
@ -33,7 +31,7 @@ func main() {
} }
``` ```
And its output : Et son résultat :
```console ```console
student@ubuntu:~/piscine/test$ go build student@ubuntu:~/piscine/test$ go build

4
subjects/unmatch.en.md

@ -1,8 +1,8 @@
## join ## unmatch
### Instructions ### Instructions
Write a function, Unmatch, that returns the element of the slice (arr) that does not have a correspondent pair. Write a function, `Unmatch`, that returns the element of the slice (arr) that does not have a correspondent pair.
- If all the number have a correspondent pair, it shoud return `-1`. - If all the number have a correspondent pair, it shoud return `-1`.

12
subjects/unmatch.fr.md

@ -1,10 +1,10 @@
## join ## unmatch
### Instructions ### Instructions
Write a function, Unmatch, that returns the element of the slice (arr) that does not have a correspondent pair. Écrire une fonction, `Unmatch`, qui retourne l'élément de la slice (arr) qui n'a pas de paire correspondante.
### Expected function ### Fonction attendue
```go ```go
func Unmatch(arr []int) int { func Unmatch(arr []int) int {
@ -12,9 +12,9 @@ func Unmatch(arr []int) int {
} }
``` ```
### Usage ### Utilisation
Here is a possible [program](TODO-LINK) to test your function : Voici un éventuel [programme](TODO-LINK) pour tester votre fonction :
```go ```go
package main package main
@ -31,7 +31,7 @@ func main() {
} }
``` ```
And its output : Et son résultat :
```console ```console
student@ubuntu:~/piscine/test$ go build student@ubuntu:~/piscine/test$ go build

Loading…
Cancel
Save