Data commit

This commit is contained in:
Ingy döt Net 2023-07-01 11:58:00 -04:00
parent 7387c8f97b
commit cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions

View file

@ -0,0 +1,9 @@
def Y[A, B](f: (A B) (A B)): A B = f(Y(f))(_)
def fib(n: Int): Option[Int] =
if (n < 0) None
else Some(Y[Int, Int](f i
if (i < 2) 1
else f(i - 1) + f(i - 2))(n))
-2 to 5 map (n (n, fib(n))) foreach println