some racket solutions to show the folder structure
This commit is contained in:
parent
99ff80637c
commit
6d754b0312
2 changed files with 29 additions and 0 deletions
11
25/euler25.rkt
Normal file
11
25/euler25.rkt
Normal file
|
@ -0,0 +1,11 @@
|
|||
#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))
|
Reference in a new issue