Data update
This commit is contained in:
parent
0df55f9f24
commit
aec8ed51b6
1045 changed files with 18889 additions and 2777 deletions
33
Task/String-concatenation/Uxntal/string-concatenation.uxnatl
Normal file
33
Task/String-concatenation/Uxntal/string-concatenation.uxnatl
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
|10 @Console &vector $2 &read $1 &pad $4 &type $1 &write $1 &error $1
|
||||
|
||||
|0100 @on-reset ( -> )
|
||||
;str3 ;str1 copy-str
|
||||
;str3 ;str2 append-str
|
||||
;str3 print-str
|
||||
#0a .Console/write DEO
|
||||
BRK
|
||||
|
||||
@print-str ( str* -: )
|
||||
&loop ( -- )
|
||||
LDAk .Console/write DEO
|
||||
INC2 LDAk ?&loop
|
||||
POP2 JMP2r
|
||||
|
||||
@copy-str ( dest* src* -: )
|
||||
STH2
|
||||
&loop ( -- )
|
||||
LDAkr STH2k STAr INC2 LDAkr STHr INC2r ?&loop
|
||||
POP2 POP2r JMP2r
|
||||
|
||||
@append-str ( dest* src* -: )
|
||||
STH2 end-str STH2r copy-str JMP2r
|
||||
|
||||
@end-str ( str* -: str* )
|
||||
!&inner
|
||||
&loop ( -- )
|
||||
INC2 &inner LDAk ?&loop
|
||||
JMP2r
|
||||
|
||||
@str1 "Uxn 00
|
||||
@str2 "tal 00
|
||||
@str3
|
||||
Loading…
Add table
Add a link
Reference in a new issue