Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #98047

Re: Python 2 vs Python 3 for teaching

From Laura Creighton <lac@openend.se>
Newsgroups comp.lang.python
Subject Re: Python 2 vs Python 3 for teaching
Date 2015-11-01 15:49 +0100
Message-ID <mailman.24.1446389385.4463.python-list@python.org> (permalink)
References <CAPTjJmoPtk30rzoDOFnN5evRrd3kDtvie1E1F0Wu_DxWTsc+jA@mail.gmail.com> <CAJ4+4apy=ibu4r6d5vj707xoLYEty7MdaOtE+9oi3VOnehB+XA@mail.gmail.com> <CAPTjJmo+st5-iUZ0Fie7EZ7YnGjWioTpLDqFdOm359g521YwhQ@mail.gmail.com>

Show all headers | View raw


In a message of Mon, 02 Nov 2015 01:27:24 +1100, Chris Angelico writes:
>On Mon, Nov 2, 2015 at 1:11 AM,  <paul.hermeneutic@gmail.com> wrote:
>> On Nov 1, 2015 2:45 AM, "Chris Angelico" <rosuav@gmail.com> wrote:
>>>
>>> I'm proud to say that a Python tutoring company has just converted its
>>> course over from teaching Python 2.7 to teaching 3.x. For the
>>> naysayers out there, it actually wasn't much of a transition;
>>
>> This would make an excellent opportunity to develop a curriculum to teach
>> students how to maintain a 2.x and 3.x code base using 2to3.
>>
>> 2.x is not going away as fast as some would like.

>I'd rather not use 2to3 there. If you want to maintain a library that
>can be used from 2.x and 3.x, it's much better to aim for the
>compatible middle - u prefixes on all Unicode strings, b prefixes on
>all byte strings, stick to ASCII where possible, etc, etc. Much easier
>than writing code for one branch and then converting to the other.

How about using six, same idea with the curriculum?

Laura

Back to comp.lang.python | Previous | Next | Find similar | Unroll thread


Thread

Re: Python 2 vs Python 3 for teaching Laura Creighton <lac@openend.se> - 2015-11-01 15:49 +0100

csiph-web