Py5, a Python version of Processing for your creative coding projects
21–30 of 34 posts
Re: Py5, a Python version of Processing for your creative coding projects
#22Why must every educational python library insist on teaching kids with global variables? I know parameters aren't easy for novices, but it feels like it's missing a lot of the value when we don't attempt to teach them...
Because it's perfectly fine for 100 line programs. Beginners don't need to write extensible code that will be maintained for 30 years on business critical systems. You start by learning what a fuckin for loop does.
I was always a bit surprised that python didn't allow "module instances" that automatically did that.
Re: Py5, a Python version of Processing for your creative coding projects
#23I can foresee the name of this causing issues in a decade or two when python releases version 5.
Re: Py5, a Python version of Processing for your creative coding projects
#24Earlier quoted context omitted.
Because it's perfectly fine for 100 line programs. Beginners don't need to write extensible code that will be maintained for 30 years on business critical systems. You start by learning what a fuckin for loop does.
Not only that, it's a relatively gentle introduction into object oriented concepts, where an instance is just like independent copies of modules, as they're using them: module.function(), with function accessing some global conceptually turns into instance.function() where function accesses some instance "global". I was always a bit surprised that python didn't allow "module instances" that automatically did that.
Re: Py5, a Python version of Processing for your creative coding projects
#25Why must every educational python library insist on teaching kids with global variables? I know parameters aren't easy for novices, but it feels like it's missing a lot of the value when we don't attempt to teach them...
Re: Py5, a Python version of Processing for your creative coding projects
#26Re: Py5, a Python version of Processing for your creative coding projects
#27Re: Py5, a Python version of Processing for your creative coding projects
#28Earlier quoted context omitted.
Not only that, it's a relatively gentle introduction into object oriented concepts, where an instance is just like independent copies of modules, as they're using them: module.function(), with function accessing some global conceptually turns into instance.function() where function accesses some instance "global". I was always a bit surprised that python didn't allow "module instances" that automatically did that.
Honestly the way I learned not to use a ton of global variables was because I used so many and would forget what they'd do. But that was back in the days of Apple // BASIC so when I was introduced to C I rejoiced. People need to learn from mistakes.
I often wonder how much "pain" is required to really learn something. I would claim that 90% of how I write code is the result of pain, not patterns, even though they often end up being similar.
Re: Py5, a Python version of Processing for your creative coding projects
#29Re: Py5, a Python version of Processing for your creative coding projects
#30Earlier quoted context omitted.
Yep. In case you don’t want to write Java you can do it in Python. But it uses the same engine
I suppose jython would be particularly useful in such cases