My take on 'Python Productivity tip for Java Programmer'. Could you give me more feedback?

Thomas Jollans t at jollybox.de
Mon Jul 11 12:00:55 EDT 2011


On 07/11/2011 05:07 PM, Anthony Kong wrote:
> Hi, all,
> 
> Lately I am giving some presentations to my colleagues about the python
> language. A new internal project is coming up which will require the use
> of python.
> 
> One of the goals of the presentations, as told by the 'sponsor' of the
> presentation, is to help the existing Java/Excel VBA programming team to
> become productive in python asap.
> 
> I have a feeling that they are asking it based on their Java/Eclipse
> experience. By productive they are actually looking for some GUI tools
> that are as helpful as Eclipse.
> 
> Having done Java programming before, I am thinking of answering the
> question this way:
> 
> 1) For many of us, vi/emacs are sufficient for python development. (I
> used vim + ctags as my primary IDE for a very long time)
> 
> 2) For a feature-rich GUI environment, we can consider pyCharm. (I was
> totally 'wowed' by it, and has convinced my last employer to purchased a
> few enterprise licenses) 
> 
> 3) The Python language itself is actually small and concise. The need
> for a full-blown IDE is less. The language itself could be counted as a
> part of the productive tool.

If your colleagues are used to Eclipse, it's almost certainly best to
continue using Eclipse, with PyDev. Don't make a big deal of the tools,
just say that many Pythonista don't use a heavy IDE, mention PyDev, and,
if you want to, recommend pyCharm.

> 4) The functional aspect of the language (e.g. map, reduce, partial)
> helps to make program shorter and easier to understand

Don't overemphasize this. Those functions can be very useful, and using
them can lead to very concise and simple code, but (big BUT) more often
than not, they're overly cryptic when compared to list comprehension and
generator expressions.

Do make a huge case for generator expressions/list comprehension, and
generators.

> 5) The 'battery included' standard library helps to avoid the need of
> complicated build tool.
> 
> 6) The interactive shell helps to test out solutions in smaller units. 

Speaking of testing: introduce them to the doctest module.

> It is probably not the team is expecting. Do you have more to add? What
> do you think about this 'answer'?

If using Jython is an option, present it! Jython will allow Java
programmers to use their existing knowledge of the Java standard library.

Explain, and make the case for, duck typing.

While actual functional programming is, as I said, a bit "out there"
from a Java/VBA standpoint, do show off function objects.

If you know what they're going to do with Python, you should point them
to relevant libraries/modules.



More information about the Python-list mailing list