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


Groups > comp.lang.python > #98100

Re: Python 2 vs Python 3 for teaching

From Chris Angelico <rosuav@gmail.com>
Newsgroups comp.lang.python
Subject Re: Python 2 vs Python 3 for teaching
Date 2015-11-03 01:10 +1100
Message-ID <mailman.63.1446473422.4463.python-list@python.org> (permalink)
References <mailman.7.1446371003.4463.python-list@python.org> <c6405c34-43cc-417b-9027-12e3ac1bbfb5@googlegroups.com>

Show all headers | View raw


On Tue, Nov 3, 2015 at 12:15 AM, beliavsky--- via Python-list
<python-list@python.org> wrote:
> I think Python 2.x is still used more than Python 3.x in scientific computing. The Python books I have in this area, such as "Python for Finance: Analyze Big Financial Data" and "Python for Data Analysis", still use Python 2.x . An aspiring computational scientist, data scientist, or financial quant may still be better off learning Python 2.x but using print(x) rather than print x and doing other things to future-proof his code.
>

That doesn't mean that Python 3 *can't* be used. Far as I know, all
the key libraries (numpy, pandas, statsmodels, scipy) are available
for Python 3 as well. Recommending the use of Python 2 simply because
all the books you have teach Python 2 is a purely circular argument.

But yes. If you're going to use Py2, aim for the common subset. Good
Py2 code is a lot more similar to good Py3 code than an enumeration of
language-level differences would suggest.

ChrisA

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


Thread

Python 2 vs Python 3 for teaching Chris Angelico <rosuav@gmail.com> - 2015-11-01 20:43 +1100
  Re: Python 2 vs Python 3 for teaching beliavsky@aol.com - 2015-11-02 05:15 -0800
    Re: Python 2 vs Python 3 for teaching Chris Angelico <rosuav@gmail.com> - 2015-11-03 01:10 +1100

csiph-web