Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Fibs in your favourite language

Name: Anonymous 2008-12-20 15:04

fibs = 1 : zipWith (+) fibs (tail fibs)

Name: Anonymous 2008-12-20 22:36

#include <math.h>

#define SQRT5 sqrtl(5)
#define PI (atanl(1) * 4)
#define FIB(n) ((1 / SQRT5) * (powl((SQRT5 + 1) / 2, n) - powl(2 / (SQRT5 + 1), n) * cosl(n * PI)))

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List