This repository has been archived on 2024-01-26. You can view files and clone it, but cannot push or open issues or pull requests.
project-euler/25/euler25.rkt

11 lines
238 B
Racket

#lang racket
(define (numdigits x)
(string-length (number->string x)))
(define (fibs limit lst)
(if (equal? (numdigits (car lst)) limit)
(length lst)
(fibs limit (cons (+ (car lst) (cadr lst)) lst))))
(fibs 1000 '(1 1))