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


Groups > comp.lang.python > #61591

Re: Experiences/guidance on teaching Python as a first programming language

Path csiph.com!usenet.pasdenom.info!news.albasani.net!rt.uk.eu.org!newsfeed.xs4all.nl!newsfeed1.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail
Return-Path <rosuav@gmail.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.001
X-Spam-Evidence '*H*': 1.00; '*S*': 0.00; 'programmer': 0.03; 'sysadmin': 0.05; 'subject:Python': 0.06; 'paths': 0.07; 'perl,': 0.07; 'subject:language': 0.09; 'url:faqs': 0.09; 'works.': 0.09; 'cc:addr:python-list': 0.11; 'language,': 0.12; 'arguments;': 0.16; 'btw': 0.16; 'c/c++,': 0.16; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'lisp': 0.16; 'semantics': 0.16; 'subject:programming': 0.16; 'substitute': 0.16; 'url:catb': 0.16; 'url:hacker-howto': 0.16; 'wait.': 0.16; 'java,': 0.16; 'weird': 0.16; 'wrote:': 0.18; 'dependent': 0.19; 'possible,': 0.19; 'thu,': 0.19; 'fit': 0.20; 'written': 0.21; 'programming': 0.22; 'cc:addr:python.org': 0.22; 'instance,': 0.24; 'lets': 0.24; 'stick': 0.24; 'regardless': 0.24; "haven't": 0.24; '(or': 0.24; 'cc:2**0': 0.24; 'logging': 0.26; 'least': 0.26; 'subject:/': 0.26; '(for': 0.26; 'header:In-Reply-To:1': 0.27; 'function': 0.29; '[1]': 0.29; 'am,': 0.29; 'unix': 0.29; "doesn't": 0.30; '[2]': 0.30; 'dec': 0.30; 'strongly': 0.30; 'message- id:@mail.gmail.com': 0.30; "i'm": 0.30; 'code': 0.31; 'easier': 0.31; 'are.': 0.31; 'easy,': 0.31; 'perl': 0.31; 'styles': 0.31; 'probably': 0.32; 'figure': 0.32; 'languages': 0.32; 'another': 0.32; 'becomes': 0.33; 'entirely': 0.33; 'style': 0.33; 'knowledge': 0.35; 'basic': 0.35; 'anywhere': 0.35; 'something': 0.35; "who's": 0.35; 'but': 0.35; 'received:google.com': 0.35; 'done': 0.36; 'url:org': 0.36; 'should': 0.36; 'two': 0.37; 'level': 0.37; 'does': 0.39; '12,': 0.39; 'functional': 0.39; 'sure': 0.39; 'changed': 0.39; 'most': 0.60; 'till': 0.61; 'pick': 0.64; 'teaching': 0.64; 'become': 0.64; 'more': 0.64; 'between': 0.67; 'believe': 0.68; 'yes': 0.68; 'everything,': 0.84; 'seldom': 0.84; '"how': 0.91; 'rusi': 0.91; 'to:none': 0.92; 'wishing': 0.93; '2013': 0.98
DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:cc :content-type; bh=0R3nVc8I0ygstRQe9T16lebxOeBAUQHx3DHglnyJRCU=; b=NoaafThJ8c8dA6ikyqY2YrkQvU6NKPzJHEvVPe+2/EPPHzgKfl+4SW5vA/QHjXGtl+ jX2KZhtBnoKPrWeiXGeep3kODs5pgur4Abh9cp31G+Aym6mgpeaQZOLcfgxGo8AE0Bk5 lRwf88o+iJkJBiwIBsEbL/XfWIjPPkQuvHBrzzwBBp9OGi5ybYPNIkV3TkAWa+HbAuOl bWIeLV9XM3ZmBJYLxCF7OzhFlvjWn1+YJ81pl0QvAShUtLsnC31vkXx1g+I0jLuw/164 9ZeCqVX4D+GZlhPOw7CMNdaOnLXiWY2VCM6bd6D+vT2fZKcoF0kFup9YaA4pIZBuu/L5 gUEQ==
MIME-Version 1.0
X-Received by 10.68.173.132 with SMTP id bk4mr2446797pbc.169.1386777851450; Wed, 11 Dec 2013 08:04:11 -0800 (PST)
In-Reply-To <ce3f38a2-a726-4d71-b538-3606a4d1ee54@googlegroups.com>
References <CAHVvXxS23g8dxO23pPTmXLo0z=QzJY_CjwMUtJcvAVfRhZa8bA@mail.gmail.com> <201312090824.25211.gheskett@wdtv.com> <52A78F6F.3060507@stoneleaf.us> <CABicbJKoN9fV48yskd5wqE79vsb5=nPGfwgOTCO+fCFMG7g8qw@mail.gmail.com> <CAPTjJmpQ9bFP66j3p-PDb2Mp88GKWKktrcFRCWQtdo6fb8LHmA@mail.gmail.com> <mailman.3887.1386762439.18130.python-list@python.org> <05fc5a48-576d-4eb9-a714-96df39f0ef1f@googlegroups.com> <mailman.3902.1386775479.18130.python-list@python.org> <ce3f38a2-a726-4d71-b538-3606a4d1ee54@googlegroups.com>
Date Thu, 12 Dec 2013 03:04:11 +1100
Subject Re: Experiences/guidance on teaching Python as a first programming language
From Chris Angelico <rosuav@gmail.com>
Cc "python-list@python.org" <python-list@python.org>
Content-Type text/plain; charset=UTF-8
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.3909.1386777861.18130.python-list@python.org> (permalink)
Lines 44
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1386777861 news.xs4all.nl 2936 [2001:888:2000:d::a6]:44721
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:61591

Show key headers only | View raw


On Thu, Dec 12, 2013 at 2:41 AM, rusi <rustompmody@gmail.com> wrote:
> Yes its always like that:
> When you have to figure 2 (or 10) line programs its a no-brainer that
> the imperative style just works.
>
> When the ten becomes ten-thousand, written by a nut who's left you with
> code whose semantics is dependent on weird dependencies and combinatorial
> paths through the code you start wishing that
>
> - your only dependencies were data dependencies
> - "Explicit is better than implicit" dinned into the nut's head
>
> which BTW are the basic tenets of FP.

And since teaching is seldom done with 10KLOC codebases, functional
style can be left till later. I strongly believe that a career
programmer should learn as many languages and styles as possible, but
most of them can wait. Start with something easy, then pick up
something harder later.

ESR in "How to become a hacker" [1] suggests learning "Python, C/C++,
Java, Perl, and LISP" [2], and do take note of his reasons _why_. I'm
not sure that Perl is so important any more (though a Unix sysadmin
should probably have at least a working knowledge of it, given the
likelihood of tripping over it at some point), and for LISP you might
substitute some other functional language, but broadly, those five
recommendations haven't changed in years and years.

Knowing multiple styles lets you learn from all of them. Pure
functional programming means the result of any function can be
determined entirely from its arguments; that doesn't fit into
everything, but it sure does make your code easier to understand when
you (mostly) stick to it. (For instance, the current logging level
might change whether a particular line does something or does nothing,
but it still fundamentally has the same meaning, and it won't change
state magically anywhere else.) And there's a lot of "similarity of
thinking" between a well-written program in one style and a
well-written program in another style, regardless of which two styles
they are.

ChrisA

[1] http://www.catb.org/esr/faqs/hacker-howto.html
[2] http://www.catb.org/esr/faqs/hacker-howto.html#skills1

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


Thread

Re: Experiences/guidance on teaching Python as a first programming language Oscar Benjamin <oscar.j.benjamin@gmail.com> - 2013-12-11 11:46 +0000
  Re: Experiences/guidance on teaching Python as a first programming language rusi <rustompmody@gmail.com> - 2013-12-11 06:44 -0800
    Re: Experiences/guidance on teaching Python as a first programming language Chris Angelico <rosuav@gmail.com> - 2013-12-12 02:24 +1100
      Re: Experiences/guidance on teaching Python as a first programming language rusi <rustompmody@gmail.com> - 2013-12-11 07:41 -0800
        Re: Experiences/guidance on teaching Python as a first programming language Mark Lawrence <breamoreboy@yahoo.co.uk> - 2013-12-11 15:53 +0000
        Re: Experiences/guidance on teaching Python as a first programming language Chris Angelico <rosuav@gmail.com> - 2013-12-12 03:04 +1100
        Re: Experiences/guidance on teaching Python as a first programming language Mark Lawrence <breamoreboy@yahoo.co.uk> - 2013-12-11 16:18 +0000
          Re: Experiences/guidance on teaching Python as a first programming language Roy Smith <roy@panix.com> - 2013-12-11 20:50 -0500
          Re: Experiences/guidance on teaching Python as a first programming language "Rhodri James" <rhodri@wildebst.org.uk> - 2013-12-12 23:50 +0000
        Re: Experiences/guidance on teaching Python as a first programming language Chris Angelico <rosuav@gmail.com> - 2013-12-12 03:25 +1100
        Re: Experiences/guidance on teaching Python as a first programming language Tim Delaney <timothy.c.delaney@gmail.com> - 2013-12-12 07:13 +1100

csiph-web