0
How do classes and instances work and interact with variables and functions?
Would like some info on how classes and instances interact with variables and functions? How do I pass variables through each of them? (Python specifically, pygame and pyganim)
3 Respuestas
+ 2
Your question begs another question. Are you familiar with Object Oriented Programming concept and principles. If you are, research on parameter passing concepts and you'll get your answer
+ 1
thank you
+ 1
Functions can have values passed to it. It's usually the values enclosed within (). Eg plus(2,1)
Functions can also RETURN a result, eg printf(plus(2,1)) may result to 3
Parameter passing enable functions to SHARE value