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

Basic Fibs

Name: Anonymous 2013-08-01 16:07

screen 12
dim as integer i = 0
dim as ulongint a = 0, b = 1, c = 0

input "? ", i
while i >= 0
    print a; " ";
    c = b
    b = a + b
    a = c
    i -= 1
wend
sleep

And they said BASIC wasn't useful for anything.

Name: Anonymous 2013-08-01 16:25

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

And they said Haskell wasn't useful for anything.

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