Search Results

Found 2 results for "954881ab869e33b12bf7891855bc1f82" across all boards searching md5.

Anonymous /a/279580074#279590187
6/11/2025, 10:17:15 PM
>>279588393
>this is gonna get voiced & animated
It's good to be a Kanojocel
Anonymous /g/105527756#105536675
6/9/2025, 4:01:04 PM
>>105536469
>for some reason multiple `define` in the body is faster than `let*` as well.
You'd have to macroexpand to see what racket is doing, but conceptually
(define (f x)
(define y 2)
(define z 3)
...

(f 1)
extends the local environment but keeps it a single alist:
(((z . 3) (y . 2) (x . 1)) calling-environment)
whereas
(define (g x)
(let* ([y 2])
([z 3])
...

(g 1)
if let* expands into nested lambdas the environment will be extended with multiple alists:
(((z . 3)) ((y . 2)) ((x . 1)) calling-environment)
so looking up x in the body of let* in g could be more expensive than x in the body of f, maybe that's it?