tasks a-s
This commit is contained in:
parent
47bf37c096
commit
b83f433714
12433 changed files with 156208 additions and 123 deletions
19
Task/Reverse-a-string/OxygenBasic/reverse-a-string-2.oxy
Normal file
19
Task/Reverse-a-string/OxygenBasic/reverse-a-string-2.oxy
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
string s="qwertyuiop"
|
||||
sys p=strptr s, le=len s
|
||||
mov esi,p
|
||||
mov edi,esi
|
||||
add edi,le
|
||||
dec edi
|
||||
(
|
||||
cmp esi,edi
|
||||
jge exit
|
||||
mov al,[esi]
|
||||
mov ah,[edi]
|
||||
mov [esi],ah
|
||||
mov [edi],al
|
||||
inc esi
|
||||
dec edi
|
||||
repeat
|
||||
)
|
||||
|
||||
print s
|
||||
Loading…
Add table
Add a link
Reference in a new issue