This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#lang lazy | |
(define g | |
(lambda (f) | |
(lambda (n) | |
(if (= n 0) | |
1 | |
(* n (f (- n 1))))))) | |
(define f |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module SimpleEval where | |
import Prelude hiding (odd, even) | |
import Data.Dynamic | |
data Expr = Val Int | Add Expr Expr | |
data Cont = HALT | EVAL Expr Cont | ADD Int Cont | |
eval :: Expr -> Int |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
""" | |
0: 1: 2: 3: 4: | |
aaaa .... aaaa aaaa .... | |
b c . c . c . c b c | |
b c . c . c . c b c | |
.... .... dddd dddd dddd | |
e f . f e . . f . f |
OlderNewer