Code Editor
function fibonacci(n) { if (n <= 1) return n; return fibonacci(n - 1) + fibonacci(n - 2); } // Example usage for (let i = 0; i < 5; i++) { console.log(`fib(${i}) = ${fibonacci(i)}`); }
Settings
Language
JavaScript
TypeScript
Python
Go
Rust
CSS
Filename
Handle
Caption
Theme
Noir
Aurora
Retro
Clay
Forest
9:16 Size
Line Numbers
Download PNG