Your code deserves to feel pretty

A code to image generator. Paste code, prettify, and download a beautiful image. See how it works

fibonacci.js
1const fib = n =>
2 n < 2 ? n : fib(n - 1) + fib(n - 2);
3
4console.log(fib(10));
0 / 10 free exportsUpgrade

Works with your language

Syntax highlighting for the languages developers share most. Open a ready-made example for any of them:

Have a question first? The FAQ covers supported formats, privacy, and pricing.