On 1/21/2014 6:38 AM, Tim Chase wrote:
> On 2014-01-21 00:00,
xeys...@gmail.com wrote:
> It's certainly a great way to consume lots of hours :)
>
> Mac OS X 10.4 should come with an older version of Python
> out-of-the-box.
Someone else said that it comes with 2.5. That will be fine for many
purposed. If you do use that, always make any classes you define a
subclass of 'object' if nothing else. In other words,
class MyClass(object): ...
# instead of
class MyClass: ...
In Python 2, the second gives you an 'old-style' or 'classic' class. You
do not need to learn about those. In Python 3, both forms give you
new-style classes, which is what you should learn.
There are a few other obsolete features to avoid, such as using strings
for exceptions.
> The install media should also include XCode if you
> want to download the latest & greatest version of Python and install
> that from source instead.
If you can do that easily, I recommend starting with the latest Python
3, especially if you want to work with non-English (non-ascii) characters.
--
Terry Jan Reedy