All Questions
Tagged with programming-practicespython
2 questions with no upvoted or accepted answers
0votes
1answer
3kviews
Instantiate a class from a config file. Where should the parse function go?
I have a class in python that is instantiated from the values of a (json) config file. I was wondering what is the best practise to do that (if there is a best practise and is not just a matter of ...
-1votes
2answers
800views
How to decide if a global variable is used inside or outside a function in Python?
In Python variables that are created outside of a function are known as global variables. However to create a global variable inside a function (a local variable), you can use the global keyword. My ...