Write an Assembly program that will declare four global variables. Assign values to the variables. Sum the first three variables and store the result in the fourth variable.
add - Integer addition. The add instruction adds together its two operands, storing the result in its second operand. Note that both operands may be registers, but only one operand may be a memory location. Syntax:
add <reg>, <reg>
add <mem>, <reg>
add <con>, <reg>
add <con>, <mem>
<con> - Any 8-, 16-, 32-, or 64-bit immediate.
Examples:
add $10, %eax - EAX is set to EAX + 10.
addb $10, (%eax) - Add 10 to the single byte stored at the memory address stored in EAX.