[A83] Re: compare strings
[Prev][Next][Index][Thread]
[A83] Re: compare strings
; input: hl,de -> string
; output: Z if equal, b = 0
cpStr:
ld b,5
cpStrLoop:
ld a,(de) ; get character of first string
cp (hl) ; compare with second string
ret nz ; return if not equal
inc hl ; goto next character
inc de ;
djnz cpStrLoop
ret
> ----------------------------------------
> From: The one and only SUCKER ... <sucker_pvn@hotmail.com>
> Sent: Wed Aug 29 21:07:52 GMT+02:00 2001
> To: <assembly-83@lists.ticalc.org>
> Subject: [A83] compare strings
>
>
>
> Somebody knows a good routine to compare two strings,
> when they can be seen as: location in ram -> location in ram
> +5 (string of 5 bytes) compared to another such a string?
> And not the TI-OS strings!!
>
> SUCKER
>
> _________________________________________________________________
> Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp
>
>
>
-----------------------------------------------------
Mail.be, Free WebMail and Virtual Office
http://www.mail.be