DGivney / assemblytutorials

This project was put together to teach myself NASM x86 assembly language on linux.
https://asmtutor.com/
654 stars 117 forks source link

Lesson 3: Null terminator vs. Newline comparison #35

Closed emorchy closed 3 years ago

emorchy commented 3 years ago

If the program looks for a zero, it will stop at a null terminator. However, the "msg" ends with a newline (hex 0x0A). In decimal, a newline is 10 instead of 0, but I believe it is more simple to compare the newline in hex (0x0A).

emorchy commented 3 years ago

After further testing, I realized that comparing with a newline would exclude the newline from the output. My apologies.