ExamPlay Light Logo
היכנס

Computer Science for IGCSE & O level - Programming (Section 3 - No. 38)

What distinguishes local variables from global variables?
Local variables can be used anywhere; global variables can only be used in one function.
Global variables are declared inside functions; local variables are not.
Local variables are only accessible within the block (e.g., function) where they are declared; global variables can be accessed throughout the program.
There is no difference; they are the same thing.

הֶסבֵּר

Scope (visibility) is the primary differentiator.

הערות (0)

התחבר כדי להגיב
פִּרסוֹמֶת
BrainBehindX Inc Logo
©2026; מופעל על ידי BrainBehindX Inc