Scopes
A scope is a program region where we can access a variable. We have local and global variables in Go. We can access local variables within the blocks we define them in. Global variables are accessible throughout the program.
Get hands-on with 1300+ tech skills courses.