View previous topic :: View next topic
|
Author |
Message |
rashmi123
New User
Joined: 04 Jun 2007 Posts: 25 Location: Pune
|
|
|
|
Hi,
Is it possible to parse a line, 80 bytes in length, for commas using assembly language? |
|
Back to top |
|
|
Craq Giegerich
Senior Member
Joined: 19 May 2007 Posts: 1512 Location: Virginia, USA
|
|
|
|
YES |
|
Back to top |
|
|
rashmi123
New User
Joined: 04 Jun 2007 Posts: 25 Location: Pune
|
|
|
|
Can you pls eleborate how that can be done? |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
One oversimplified way (via pseudo code):
Code: |
point to the first byte - load the address into a register
loop:
is the current byte a comma?
yes - do whatever you want when you find a comma
no - increment the value in the register and check for end
endloop
|
|
|
Back to top |
|
|
|