Answers for "what is global keyword in python"

11

global in python

a = 'this is a global variable'
def yourFunction(arg):
    #you need to declare a global variable, otherwise an error
    global a
    return a.split(' ')
Posted by: Guest on March-14-2020

Python Answers by Framework

Browse Popular Code Answers by Language