Tuesday, 29 May 2012

Exercise 2


Write a single assembly language program to perform the following tasks:

·         Count the number of characters in this given constant string “*my*oh*dear*”.
·         Display the number of characters in the given constant string.
·         Count the number of time(s) the hyphen ‘ * ‘  appear in the given constant string.
·         Display the number time(s) the hyphen ‘ * ‘ appear in the given constant string.

The program is to start at address $1000.  The stack is to start at address $7FFE. ASCII code for carriage return is $0D 

No comments:

Post a Comment