RSS Forums RSS
Please support our Assembly advertiser: Programming Forums
Views: 1000 | Replies: 0
Reply
Join Date: Nov 2004
Posts: 20
Reputation: skeet123 is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
skeet123 skeet123 is offline Offline
Newbie Poster

Help with machine language

  #1  
Mar 17th, 2007
I am having trouble trying to get this machine language program to work with pep/8. Write a machine language program to input two one-digit numbers from the user, add them, and output the one-digit sum. Beacuse this program is at the machine language level you only should use character input, which is why theis question only requires single-digit numbers.

49 00 11 ; input first num
79 00 13 ; add the first and second num
A1 00 15 ;convert the sum to character
F1 00 10 ; store the character
51 00 10 ; output the character
00 ; stop

49 00 11 79 00 13 A1 00 15 F1 00 10 51 00 10 00 00 00 zz
Last edited by WaltP : Mar 21st, 2007 at 3:45 am. Reason: Remove the gawdawful color tag
AddThis Social Bookmark Button
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

Thread Tools Display Modes
Forums | Blogs | Tutorials | Code Snippets | Whitepapers | RSS Feeds | Advertising
All times are GMT -4. The time now is 1:14 pm.
Newsletter Archive - Sitemap - Privacy Statement - Contact Us
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC