1’s complement of number in Assemby -masm 8086

1’s complement of number in Assemby -masm 8086

org 100h
.stack 100h
.data
var DW 0101010101010101b
.code
;Initilization of data segment
mov ax,@data
mov DS,ax
;not inverts all bits
mov ax,var
not ax
mov var,ax
;to terminte program
mov ah,4ch
int 21h
ret

Advertisements

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