Programming Tutorial for absolute beginners

Clodoaldo Pinto clodoaldo.pinto at gmail.com
Tue Apr 11 13:22:24 EDT 2006


Frank Millman wrote:
> Marc 'BlackJack' Rintsch wrote:
> > In <1144572585.147756.144240 at i40g2000cwc.googlegroups.com>, Frank Millman
> > wrote:
> >
> > > Then you can mention that, if they just want the integer portion, they
> > > can use int(3/2). I think that most people with the slightest
> > > understanding of basic arithmetic will relate to this without a
> > > problem.
> >
> > Or instead of converting the `float` back to an `int`, they can use
> > integer division:  ``3 // 2``
> >
>
> I had thought of that. The reason I did not suggest it is that, as I
> understand it, this tutorial is not about how to learn Python, it is
> about teaching programming to the absolute beginner.

Right !!

>
> I imagine (hope I am not making invalid assumptions here) that Python
> was chosen as a base because it is easy and intuitive to learn, and in
> most cases it is. It just happens that division is one area where it is
> a bit awkward.

Right again !!

Although the Python way is almost always easy to learn I won't be
pythonic (as in specific to Python) where it won't help.

Regards, Clodoaldo




More information about the Python-list mailing list