Advertisement
Guest User

Untitled

a guest
Nov 13th, 2019
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.30 KB | None | 0 0
  1. # Local versus Global def local(): # m doesn't belong to the scope defined by the local function # so Python will keep looking into the next enclosing scope. # m is finally found in the global scope print(m, 'printing from the local scope') m = 5 print(m, 'printing from the global scope') local()
  2.  
  3. (Page 29).
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement