While it may true I am trying to write Python as if it were PHP, that is explained by me knowing PHP and not knowing Python. I started coding in 1967 and have experience of Fortran 4, Algol 68, COBOL, Pascal, Basic, PLAN, asm and others. You have decided Python does things the "right way" and won't have it any other way.
No, that's not true at all. Python does it the way Guido designed it. It is what it is. It is consistent, well-documented and well-defined. The key point is that you don't get to say Python is wrong just because it does things differently from what you're used to. If it doesn't agree with you, there are lots of others.
It is NOT true that PHP has to have its functions defined before use. Python could do it simply by doing a dual pass over the code.
Yes, but it doesn't. Neither does C or C++. You simply learn that main() goes at the bottom, and the things it needs are above.
I would also point out that using classes eliminates this problem, because the code for the class is all parsed before any instances of the class can be instantiated.
Event handling occurs after "app.MainLoop()" is executed, so the logical place to put the code lines is after the "app.MainLoop()" line.
OOP imposes a nonsensical structure and line ordering on things which are logically top to bottom.
No, that's silly. You are inventing your own arbitrary criteria and measuring a new language against those criteria. What you are describing has nothing to do with "logical". Get to know Python first, by reading code from successful projects, and come back to us after you've had time to absorb the philosophy.
I am not going to get confused by this approach, although I can see that a room full of programmers all working on the same project might have a problem.
25 years of hugely successful development experience with Python suggests you are incorrect.
···
On Apr 17, 2019, at 9:19 PM, Dave Kimble <dave.kimble.2@gmail.com> wrote:
—
Tim Roberts, timr@probo.com
Providenza & Boekelheide, Inc.