Address of a variable: Difference between revisions

Content added Content deleted
Line 24: Line 24:
=={{header|8086 Assembly}}==
=={{header|8086 Assembly}}==
When programming in assembly language yourself (i.e. not having a compiler do it for you), generally the addresses of variables are known in advance and chosen by the programmer rather than dynamically determined by the compiler. Therefore you pretty much always know a variable's address at all times. However there is a little more work that needs to be done to get the address in 8086 Assembly compared to assembly for other machines.
When programming in assembly language yourself (i.e. not having a compiler do it for you), generally the addresses of variables are known in advance and chosen by the programmer rather than dynamically determined by the compiler. Therefore you pretty much always know a variable's address at all times. However there is a little more work that needs to be done to get the address in 8086 Assembly compared to assembly for other machines.
{{works with|https://www.dosbox.com|DOSBox}}
{{works with|https://www.dosbox.com DOSBox}}


<lang asm>.model small
<lang asm>.model small