1) Convert the following pseudo-code to assembly language:
a = 0 b=2
for (i=0, i<=9 , i+2)
{
a=a+b
cout<<"number="<<a<<endl;
a++
}
Expert's answer
;MS Visual Studio 2017
INCLUDE irvine32.inc.data
.code
main PROC
moveax, 0; a = 0movebx, 2; b = 2movecx, 0; i = 0;
forI:addeax, ebx; a=a+bcall writeDec
call crlf
inceax;a++addecx,2; i+2cmpecx, 9jle forI
call crlf
call crlf
call waitMsg
exit
main ENDP
END main
"assignmentexpert.com" is professional group of people in Math subjects! They did assignments in very high level of mathematical modelling in the best quality. Thanks a lot