[Jprogramming] Recurring holiday amusement

km km at math.uh.edu
Mon Dec 24 03:00:49 UTC 2012


Write a conjunction recur and verbs fib, arith, and e that do the following

    fib recur 5 [ 1 1  NB. five additional terms of Fibonacci sequence
 1 1 2 3 5 8 13
    0.5&arith recur 5 [ 3
 3 3.5 4 4.5 5 5.5
    1&e recur 5 [ ''
 1 1 0.5 0.166667 0.0416667
    +/ 1&e recur 10 [ ''
 2.71828
    +/ _1&e recur 10 [ ''
 0.367879
    ^ 1 _1
 2.71828 0.367879

Conjunction recur helps create "recursive" lists.

Kip Murray

Sent from my iPad


More information about the Programming mailing list