
string s="abcdefghijklmnopqrstuvwxyz"

function Reverse(string s) as string
string t=s
int le=len t
int i
for i=1 to le
mid t,i,mid s,le-i+1
next
return t
end function

print reverse s

function Reverse(string s) as string
string t=s
int le=len t
byte a at (strptr s)
byte b at (le-1+strptr t)
int i
for i=1 to le
b=a : @b-- : @a++
next
return t
end function

print reverse s

function Reverse(string s) as string
string t=s
int le=len t
addr edi,t
addr esi,s
mov ecx,le
dec ecx
(
 mov al,[esi]
 mov [edi+ecx],al
 inc esi
 dec ecx
 jge repeat
)
return t
end function


print reverse s
