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,24 @@
: vector ( ...n"- )
here [ &, times ] dip : .data ` swap ` + ` @ ` do ` ; ;
: .I dup @ ^buffer'add ;
: .V dup 1 + @ ^buffer'add ;
: .X dup 2 + @ ^buffer'add ;
[ .I .X drop ]
[ .V .I .I .I drop ]
[ .V .I .I drop ]
[ .V .I drop ]
[ .V drop ]
[ .I .V drop ]
[ .I .I .I drop ]
[ .I .I drop ]
[ .I drop ]
&drop
10 vector .digit
: record ( an- )
10 /mod dup [ [ over 2 + ] dip record ] &drop if .digit ;
: toRoman ( n-a )
here ^buffer'set
dup 1 3999 within 0 =
[ "EX LIMITO!\n" ] [ "IVXLCDM" swap record here ] if ;