Program to find teo’s Complement……

Program to find two’s complement of data stored at memory address 2100H….
For two’s complement again we will use XRI operation and add 01H to its answers. Meaning we are finding ones complement then adding it with 1 to get the twos complement.
———-
LDA 2100H;
XRI FFH;
ADI A, 01;
STA 2101H;
HLT;
———–

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s