PasteRack.org
Paste # 78885
2019-08-26 18:03:42

Fork as a new paste.

Paste viewed 452 times.


Embed:

  1. #lang racket
  2. (define fibs (stream-cons 1 (stream-cons 1 (map + fibs (rest fibs)))))
  3. (sequence->list (take 15 fibs))

=>

take: contract violation

  expected: exact-nonnegative-integer?

  given: #<stream>

  argument position: 2nd

  other arguments...:

   15