noun
external variable
In programming, a variable defined outside the current scope or module, accessible from multiple parts of a program.
この関数は外部変数に依存している。
This function depends on an external variable.
外部変数の値を変更すると、プログラム全体に影響する。
Changing the value of an external variable affects the entire program.
グローバル変数 is a specific kind of external variable accessible from anywhere in the program, while 外部変数 may refer to any variable defined outside a given scope, including those in other files or modules.
局所変数 (local variable) is the opposite of 外部変数; it is defined within a function or block and not accessible from outside.
Compound of 外部 (external) and 変数 (variable), a straightforward calque from English 'external variable' used in computing contexts.