Skip to content

Commit

Permalink
reword sentence about local variable "overwriting" global variable
Browse files Browse the repository at this point in the history
  • Loading branch information
glennj committed Jan 7, 2025
1 parent 0626d48 commit 9aa0d70
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion concepts/functions/introduction.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ If you declare the variables with the `local` command, the _scope_ of the variab
Otherwise, the variable is placed in the _global scope_.

Local variables can have the same name as a global variable.
In that case, the local variable _temporarily_ overrides the global one, and the global value is restored when the function returns.
In that case, the local variable takes precedence over the global variable.

```bash
x=5
Expand Down

0 comments on commit 9aa0d70

Please sign in to comment.