Browse Source

fixi activebits readme from hackaton

pull/194/head
lee 5 years ago
parent
commit
d709c6491b
  1. 12
      subjects/activebits.en.md
  2. 12
      subjects/activebits.fr.md

12
subjects/activebits.en.md

@ -2,7 +2,7 @@
### Instructions
Write a function, ActiveBitsthat, 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.
The function must have the next signature.
@ -23,11 +23,11 @@ package main
import (
"fmt"
student ".."
piscine ".."
)
func main() {
nbits := student.ActiveBits(7)
nbits := piscine.ActiveBits(7)
fmt.Println(nbits)
}
```
@ -35,8 +35,8 @@ func main() {
And its output :
```console
student@ubuntu:~/student/activebits$ go build
student@ubuntu:~/student/activebits$ ./activebits
student@ubuntu:~/piscine/test$ go build
student@ubuntu:~/piscine/test$ ./test
10
student@ubuntu:~/student/activebits$
student@ubuntu:~/piscine/test$
```

12
subjects/activebits.fr.md

@ -2,7 +2,7 @@
### Instructions
Write a function, ActiveBitsthat, 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.
The function must have the next signature.
@ -23,11 +23,11 @@ package main
import (
"fmt"
student ".."
piscine ".."
)
func main() {
nbits := student.ActiveBits(7)
nbits := piscine.ActiveBits(7)
fmt.Println(nbits)
}
```
@ -35,8 +35,8 @@ func main() {
And its output :
```console
student@ubuntu:~/student/activebits$ go build
student@ubuntu:~/student/activebits$ ./activebits
student@ubuntu:~/piscine/test$ go build
student@ubuntu:~/piscine/test$ ./test
10
student@ubuntu:~/student/activebits$
student@ubuntu:~/piscine/test$
```

Loading…
Cancel
Save