Python Function Modify Global Variable And Static Variable