I don't think this is in a tutorial, so I'll ask it here.
Do variable values from one procedure save over to another procedure if they are declared globally?
I don't think this is in a tutorial, so I'll ask it here.
Do variable values from one procedure save over to another procedure if they are declared globally?
Active only during the Summer...
yeah, if they are declared globally, every function can acces themeven different threads can acces them
![]()
Infractions, reputation, reflection, the dark side of scripting, they are.
So if in one procedure I said x:=5 then 5 procedures later it would still be 5 assuming no other function changed it?
Active only during the Summer...
yeah
SCAR Code:program New;
var
MyVar : integer; //global var
Procedure SetVar(X: integer);
begin
MyVar := X;
end;
Procedure WriteVar;
begin
WriteLn(IntToStr(MyVar));
end;
begin
SetVar(1);
WriteVar;
end.
Infractions, reputation, reflection, the dark side of scripting, they are.
Okay, thanks.
Active only during the Summer...
There are currently 1 users browsing this thread. (0 members and 1 guests)