how to make function in python and use it globally code example Example: python global variables global var1 var1 = 'whatever'