asked 122k views
0 votes
Which type of variable is visible to every module and the entire program?

Answers:
a) Local
b) Pass by reference
c) Pass by value
d) Global

asked
User Johnmph
by
8.5k points

1 Answer

5 votes

Final answer:

A global variable is one that can be accessed by any part of a program, declared outside all functions.

Step-by-step explanation:

The type of variable that is visible to every module and the entire program is known as a d. global variable. In contrast to local variables which are accessible only within the function or block in which they are declared, global variables are declared outside of all functions, which allows them to be accessed by any part of the program. For example, if you declare a variable at the top of your program file, it can be used by any function or module within that program.

answered
User Rachid
by
8.0k points

No related questions found