~rabbits/ornithologics

Combinatory logic, written in Tal

refs

main
browse  log 

clone

read-only
https://git.sr.ht/~rabbits/ornithologics
read/write
git@git.sr.ht:~rabbits/ornithologics

You can also use your local clone with git send-email.

#Ornithologics

A combinatory logic playground, written in Uxntal.

#Build

You must have the Uxn assembler and emulator.

uxnasm src/ornithologics.tal bin/i.rom && uxnemu bin/i.rom

#Example

Adding two numbers together:

B(2)(3)fx , or B(WB)(SB(WB))fx

The resulting stack should be:

f(f(f(f(f(fx)))))
( prelude ) ;nil JSR2 ;x ;cons JSR2 ;f ;cons JSR2
( 3 ) ;nil JSR2 ;nil JSR2 ;b ;cons JSR2 ;w ;cons JSR2 ;cons JSR2 ;b ;cons JSR2 ;s ;cons JSR2 ;cons JSR2
( 2 ) ;nil JSR2 ;b ;cons JSR2 ;w ;cons JSR2 ;cons JSR2
( end ) ;b ;cons JSR2
( eval )
;eval JSR2
( halt )
#0101 #0e DEO2

#Extras