What language is this? Looks similar to Basic/QBasic with a mash of FoxPro..
If this is assembly, you're going to have to explain more and the interpreter/assembler being used.. What are the details of the subject (what are you currently learning in CS.. specific topic)?
As for what truly happens at the lowest possible level of any language when you ask for input:
The variable is loaded into a register or pushed directly onto the stack or the "effective address" is loaded (LEA instruction). When input is gathered, it writes to that address OR to the intermediary.
Ex (32-bit assembly with CRT):
ASM Code:
push variable ;memory location of variable.
push format
call [scanf]
add esp, 0x08
;OR:
push esp ;variable is already on the stack being pushed onto the stack.
push format
call [scanf]
pop esp
add esp, 0x04
;OR:
xor eax, eax
mov eax, variable ;intermediary is eax. //variable is moved into a register. Register is then pushed onto the stack.
push eax
push format
call [scanf]
pop eax
add esp, 0x04
;OR:
LEA eax, [EBP - 4] ;stack allocated variables. Variable is in stack allocated memory. Memory location is simply loaded.
LEA edx, [EBP - 8]
push eax ;variable
push edx ;format
call [scanf]
pop edx
pop eax
In 16-bit assembly, it's the same thing but you won't be using scanf.. you'd be using interupts:
It all depends on the language and how the optimizer decides to work or how you decide to do it.. But this is just what happens at the lowest level..
We need to know what you're working with (what language as well) in order to answer your questions properly.. Just saying "Help me" isn't enough. Can't do anything with that. Throwing a bunch of assembly at you, isn't my idea of fun. Well.. it is fun but meh.. doesn't help. Give more details for better help.