Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   Python (http://www.velocityreviews.com/forums/f43-python.html)
-   -   Re: Yet another Python textbook (http://www.velocityreviews.com/forums/t954657-re-yet-another-python-textbook.html)

Chris Angelico 11-20-2012 08:09 AM

Re: Yet another Python textbook
 
On Tue, Nov 20, 2012 at 7:02 PM, Pavel Solin <solin.pavel@gmail.com> wrote:
> Perhaps you are right. Is there any statistics of how many Python
> programmers are using 2.7 vs. 3? Most of people I know use 2.7.


If you're teaching Python, the stats are probably about zero for zero.
Start them off on Py3 and help move the world forward.

ChrisA

wxjmfauth@gmail.com 11-20-2012 02:57 PM

Re: Yet another Python textbook
 
Le mardi 20 novembre 2012 09:09:50 UTC+1, Chris Angelico a écrit*:
> On Tue, Nov 20, 2012 at 7:02 PM, Pavel Solin <solin.pavel@gmail.com> wrote:
>
> > Perhaps you are right. Is there any statistics of how many Python

>
> > programmers are using 2.7 vs. 3? Most of people I know use 2.7.

>
>
>
> If you're teaching Python, the stats are probably about zero for zero.
>
> Start them off on Py3 and help move the world forward.
>
>
>
> ChrisA


--------

Do not count with me.

The absurd flexible string representation has practically
borrowed the idea to propose once Python has a teaching tool.

jmf


Chris Angelico 11-20-2012 09:00 PM

Re: Yet another Python textbook
 
On Wed, Nov 21, 2012 at 1:57 AM, <wxjmfauth@gmail.com> wrote:
> Le mardi 20 novembre 2012 09:09:50 UTC+1, Chris Angelico a écrit :
>> On Tue, Nov 20, 2012 at 7:02 PM, Pavel Solin <solin.pavel@gmail.com> wrote:
>>
>> > Perhaps you are right. Is there any statistics of how many Python

>>
>> > programmers are using 2.7 vs. 3? Most of people I know use 2.7.

>>
>>
>>
>> If you're teaching Python, the stats are probably about zero for zero.
>>
>> Start them off on Py3 and help move the world forward.
>>
>>
>>
>> ChrisA

>
> --------
>
> Do not count with me.
>
> The absurd flexible string representation has practically
> borrowed the idea to propose once Python has a teaching tool.


To the OP: jmf has an unnatural hatred of Python 3.3 and PEP 393
strings. Take no notice; the rest of the world sees this as a huge
advantage. Python is now in a VERY small group of languages (I'm aware
of just one other) that have absolutely proper Unicode handling *and*
efficient string handling.

ChrisA

Mark Lawrence 11-20-2012 09:55 PM

Re: Yet another Python textbook
 
On 20/11/2012 21:00, Chris Angelico wrote:
>
> To the OP: jmf has an unnatural hatred of Python 3.3 and PEP 393
> strings. Take no notice; the rest of the world sees this as a huge
> advantage. Python is now in a VERY small group of languages (I'm aware
> of just one other) that have absolutely proper Unicode handling *and*
> efficient string handling.
>
> ChrisA
>


Rather more polite than the response I've had sitting in my drafts
folder for several hours. I'm so pleased I didn't send it, I can now
happily delete it and move on :)

--
Cheers.

Mark Lawrence.


Chris Angelico 11-20-2012 10:25 PM

Re: Yet another Python textbook
 
On Wed, Nov 21, 2012 at 8:55 AM, Mark Lawrence <breamoreboy@yahoo.co.uk> wrote:
> On 20/11/2012 21:00, Chris Angelico wrote:
>>
>>
>> To the OP: jmf has an unnatural hatred of Python 3.3 and PEP 393
>> strings. Take no notice; the rest of the world sees this as a huge
>> advantage. Python is now in a VERY small group of languages (I'm aware
>> of just one other) that have absolutely proper Unicode handling *and*
>> efficient string handling.
>>
>> ChrisA
>>

>
> Rather more polite than the response I've had sitting in my drafts folder
> for several hours. I'm so pleased I didn't send it, I can now happily
> delete it and move on :)


Polite is good :)

Incidentally, if anyone else knows of a language that fits the
description above, I'd be most curious. Maybe we're going to see a
revolution in language design - with everyone adopting this sort of
string handling - or in language usage - with everyone adopting Python
or Pike. Hmm. We're having major security issues with Joomla, I wonder
how hard it'd be to convince our webmaster to switch to a Python-based
web framework...

Dreaming-ly yours,

ChrisA

wxjmfauth@gmail.com 11-21-2012 02:49 PM

Re: Yet another Python textbook
 
Le mardi 20 novembre 2012 22:00:49 UTC+1, Chris Angelico a écrit*:
> On Wed, Nov 21, 2012 at 1:57 AM, <wxjmfauth@gmail.com> wrote:
>

-----

> To the OP: jmf has an unnatural hatred of Python 3.3 and PEP 393
>
> strings.



No. Not at all. I'm mainly and deeply disappointed.

jmf

wxjmfauth@gmail.com 11-21-2012 02:49 PM

Re: Yet another Python textbook
 
Le mardi 20 novembre 2012 22:00:49 UTC+1, Chris Angelico a écrit*:
> On Wed, Nov 21, 2012 at 1:57 AM, <wxjmfauth@gmail.com> wrote:
>

-----

> To the OP: jmf has an unnatural hatred of Python 3.3 and PEP 393
>
> strings.



No. Not at all. I'm mainly and deeply disappointed.

jmf

Colin J. Williams 11-21-2012 05:03 PM

Re: Yet another Python textbook
 
On 20/11/2012 4:00 PM, Chris Angelico wrote:
> On Wed, Nov 21, 2012 at 1:57 AM, <wxjmfauth@gmail.com> wrote:
>> Le mardi 20 novembre 2012 09:09:50 UTC+1, Chris Angelico a écrit :
>>> On Tue, Nov 20, 2012 at 7:02 PM, Pavel Solin <solin.pavel@gmail.com> wrote:
>>>
>>>> Perhaps you are right. Is there any statistics of how many Python
>>>
>>>> programmers are using 2.7 vs. 3? Most of people I know use 2.7.
>>>
>>>
>>>
>>> If you're teaching Python, the stats are probably about zero for zero.
>>>
>>> Start them off on Py3 and help move the world forward.
>>>
>>>
>>>
>>> ChrisA

>>
>> --------
>>
>> Do not count with me.
>>
>> The absurd flexible string representation has practically
>> borrowed the idea to propose once Python has a teaching tool.

>
> To the OP: jmf has an unnatural hatred of Python 3.3 and PEP 393
> strings. Take no notice; the rest of the world sees this as a huge
> advantage. Python is now in a VERY small group of languages (I'm aware
> of just one other) that have absolutely proper Unicode handling *and*
> efficient string handling.
>
> ChrisA
>

It's interesting to see that someone else finds the format function to
be a pain. Perhaps the problem lies with the documentation.

Colin W.

Dave Angel 11-21-2012 10:58 PM

Re: Yet another Python textbook
 
On 11/21/2012 05:17 PM, Chris Angelico wrote:
> <snip>
>
>
> That said, though, I'm just glad that %-formatting is staying. It's an
> extremely expressive string formatting method, and exists in many
> languages (thanks to C's heritage). Pike's version is insanely
> powerful, Python's is more like C's, but all three are compact and
> convenient.
>
> str.format(), on the other hand, is flexible. It strikes me as rather
> more complicated than a string formatting function needs to be, but
> that may be a cost of its flexibility.
>
>


Some don't realize that one very powerful use for the .format style of
working is that it makes localization much more straightforward. With
the curly brace approach, one can translate the format string into
another language, and if the parameters have to be substituted in
another order, it's all in one place.

Twenty years ago, I implemented such a thing for our product (C++), for
just that reason. I'm sure that by now, the libraries exist somewhere
in the C++ stdlibs, or at least in Boost.

--

DaveA


Ian Kelly 11-21-2012 11:11 PM

Re: Yet another Python textbook
 
On Wed, Nov 21, 2012 at 3:58 PM, Dave Angel <d@davea.name> wrote:
> Some don't realize that one very powerful use for the .format style of
> working is that it makes localization much more straightforward. With
> the curly brace approach, one can translate the format string into
> another language, and if the parameters have to be substituted in
> another order, it's all in one place.


It only matters with positional placeholders, though. You can achieve
the same thing using named placeholders, which both major formatting
styles support.


All times are GMT. The time now is 10:24 PM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.