13 lines
150 B
Plaintext
13 lines
150 B
Plaintext
import log
|
|
|
|
main() {
|
|
log.number(fibonacci(10))
|
|
}
|
|
|
|
fibonacci(x Int) -> Int {
|
|
if x <= 1 {
|
|
return x
|
|
}
|
|
|
|
return fibonacci(x - 1) + fibonacci(x - 2)
|
|
} |