[Assembly] Community 2 decimal integer
For communities to be 2 large integer, then we first need to import and export are 2 large integer decimal system was. You can look at Import and export of raw.
Here is the code public 2 decimal integer:
.model small .stack 100 .data inputA db 'Nhap so A = $' inputB db 'Nhap so B = $' outputResult db 'Tong A + B = $' CLRF db 13, 10, '$' .code main proc mov ax, @data mov ds, ax mov ah, 9 ; hien thi "Nhap so A = " lea dx, inputA int 21h call inputDec ; goi CTC nhap so thu nhat he 10 push ax ; luu ax da nhap lai call nextLine ; xuong dong mov ah, 9 ; lam tuong tu voi so thu hai lea dx, inputB int 21h call inputDec mov bl, al call nextLine pop ax ; goi ax tu Stack ra call sum ; goi ham tinh tong 2 so (trong ax va bx) push ax ; luu ax lai mov ah, 9 ; hien thi KQ lea dx, outputResult int 21h pop ax call outputDec ; goi CTC hien thi KQ mov ah, 4ch int 21h main endp sum proc ; CTC con tinh tong 2 so add ax, bx ret sum endp nextLine proc ; CTC xuong dong mov ah, 9 lea dx, CLRF int 21h ret nextLine endp include includeinputDecProc.asm ; tep chua CTC nhap so he 10 include includeoutputDecProc.asm ; tep chua CTC hien thi so he 10 end main
you rely on all Import and export of raw or can see 2 file inputDecProc.asm and outputDecProc.asm
I asked why some public program it just write simple.
Examples community 2 of a,b.
Load a;
add b;
move c;
printf c;
New her learn about this language, not understand it very, thanks you explain households with nhé.
Maybe that's just the community 2 of which each number only 1 number.
Waiter , he notes the input and output components are not you ? thank you!
Long time back new blog to learn more troops and DC 1 few useful content
call call only sum the retrieved ax 1 Star Times sums are