rudus/sandbox.ld
Scott Richmond c00e1275fd fix and & or
2025-06-22 20:26:08 -04:00

16 lines
230 B
Plaintext

fn my_eq? {
(x, y, ...zs) -> if eq? (x, y)
then loop (y, zs) with {
(a, [b]) -> and (eq? (a, x), eq? (b, x))
(a, [b, ...cs]) -> if eq? (a, x)
then recur (b, cs)
else false
}
else false
}
my_eq? (1, 1, 3)