MCPcopy Create free account
hub / github.com/IntegralPilot/rustc_codegen_jvm / fib_recursive

Function fib_recursive

tests/binary/fibonacci/src/main.rs:19–25  ·  view source on GitHub ↗
(n: usize)

Source from the content-addressed store, hash-verified

17}
18
19fn fib_recursive(n: usize) -> usize {
20 match n {
21 0 => 0,
22 1 => 1,
23 _ => fib_recursive(n - 1) + fib_recursive(n - 2),
24 }
25}
26
27fn main() {
28 assert!(fibonacci(0) == 0);

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected