Computer Science, asked by reshmi3152004, 7 months ago

Explain the types of scopes for variable or LEGB rule with example.​

Answers

Answered by DarshikaSingh3700
1

Explanation:

The scope of a name or variable depends on the place in your code where you create that variable. The Python scope concept is generally presented using a rule known as the LEGB rule. The letters in the acronym LEGB stand for Local, Enclosing, Global, and Built-in scopes....

Similar questions