473,769 Members | 2,245 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Article of interest: Python pros/cons for the enterprise

This is part of a series examining the strengths and weaknesses of
various scripting languages, with particular attention to enterprise
(read: big company) use.

You Used Python to Write WHAT?
Python is a powerful, easy-to-use scripting language suitable for use
in the enterprise, although it is not right for absolutely every use.
Python expert Martin Aspeli identifies when Python is the right
choice, and when another language might be a better option.
http://www.cio.com/article/185350
Feb 20 '08 #1
62 2916
You Used Python to Write WHAT?
http://www.cio.com/article/185350
"""
Furthermore, the power and expressivity that Python offers means
that it may require more skilled developers.
[...down to the summary...]
Python may not be an appropriate choice if you:
[...]
* Rely on teams of less-experienced programmers. These
developers may benefit from the wider availability of training
for languages like Java and are less likely to make mistakes with
a compile-time, type-checked language.
"""

Oh noes! You might need competent programmers that actually
understand what they're doing!

(they might even have to write testing code to make sure their
code works as intended...it's a good thing that Python includes
unittest and doctest modules in the stock install)

Sigh. Any programmer that can overcome the hurdles of learning
Java or C# can quickly/easily pick up Python as long as they're
willing to unlearn some bad habits.

-tkc
Feb 20 '08 #2
On Feb 20, 8:58 am, Tim Chase <python.l...@ti m.thechases.com wrote:
You Used Python to Write WHAT?
http://www.cio.com/article/185350

"""
Furthermore, the power and expressivity that Python offers means
that it may require more skilled developers.
[...down to the summary...]
Python may not be an appropriate choice if you:
[...]
* Rely on teams of less-experienced programmers. These
developers may benefit from the wider availability of training
for languages like Java and are less likely to make mistakes with
a compile-time, type-checked language.
"""

Oh noes! You might need competent programmers that actually
understand what they're doing!

(they might even have to write testing code to make sure their
code works as intended...it's a good thing that Python includes
unittest and doctest modules in the stock install)

Sigh. Any programmer that can overcome the hurdles of learning
Java or C# can quickly/easily pick up Python as long as they're
willing to unlearn some bad habits.

C++ is a compile-time, type-checked language, which means it is
totally safer for newbies than Python. Yep, your big company is
totally safe with newbie C++ programmers.
Carl Banks
Feb 21 '08 #3
Carl Banks a écrit :
On Feb 20, 8:58 am, Tim Chase <python.l...@ti m.thechases.com wrote:
>>You Used Python to Write WHAT?
http://www.cio.com/article/185350
"""
Furthermore, the power and expressivity that Python offers means
that it may require more skilled developers.
[...down to the summary...]
Python may not be an appropriate choice if you:
[...]
* Rely on teams of less-experienced programmers. These
developers may benefit from the wider availability of training
for languages like Java and are less likely to make mistakes with
a compile-time, type-checked language.
"""
(snip)
>
C++ is a compile-time, type-checked language, which means it is
totally safer for newbies than Python. Yep, your big company is
totally safe with newbie C++ programmers.
Mouarf ! Brillant demonstration, thanks Carl !-)

(and BTW, +1 QOTW)
Feb 21 '08 #4
On Feb 21, 10:55 am, Bruno Desthuilliers <bruno.
42.desthuilli.. .@wtf.websitebu ro.oops.comwrot e:
Carl Banks a écrit :
[...]
C++ is a compile-time, type-checked language, which means it is
totally safer for newbies than Python. Yep, your big company is
totally safe with newbie C++ programmers.

Mouarf ! Brillant demonstration, thanks Carl !-)

(and BTW, +1 QOTW)
Newbies learn, and the fundamental C++ lessons are usually learnt
quite easily. Unless we're talking about idiots, that is, but in this
case at least C++ is likely to make their deficiencies evident sooner
than most other programming languages. So, yes, your big company is
likely to be safer with newbie C++ programmers than with Python newbie
programmers.

Had we been speaking of productivity... but we weren't, were we?

Cheers,
Nicola Musatti
Feb 21 '08 #5
On Behalf Of Nicola Musatti
Newbies learn, and the fundamental C++ lessons are usually
learnt quite easily. Unless we're talking about idiots, that
is, but in this case at least C++ is likely to make their
deficiencies evident sooner than most other programming
languages. So, yes, your big company is likely to be safer
with newbie C++ programmers than with Python newbie programmers.
The danger of memory leaks alone makes C++ a decidedly newbie-unfriendly
language. Java I might go along with, but C++?

Regards,
Ryan Ginstrom
(who learned C++ before Python and has grappled with his share of memory
bugs)

Feb 21 '08 #6
Please do not reply personally to newsgroup postings, thank you.

On Thu, Feb 21, 2008 at 4:00 PM, Tim Chase
<py*********@ti m.thechases.com wrote:
[...]

--
Nicola.Musatti <atgmail <dotcom
Home: http://nicola.musatti.googlepages.com/home
Blog: http://wthwdik.wordpress.com/
Feb 21 '08 #7
On Feb 21, 3:46 pm, "Ryan Ginstrom" <softw...@ginst rom.comwrote:
On Behalf Of Nicola Musatti
Newbies learn, and the fundamental C++ lessons are usually
learnt quite easily. Unless we're talking about idiots, that
is, but in this case at least C++ is likely to make their
deficiencies evident sooner than most other programming
languages. So, yes, your big company is likely to be safer
with newbie C++ programmers than with Python newbie programmers.

The danger of memory leaks alone makes C++ a decidedly newbie-unfriendly
language. Java I might go along with, but C++?
Memory *leaks* are just as common in garbage collected languages if
not more, thanks to C++'s deterministic destruction and its standard
library, especially if complemented with smart pointers such as
Boost's shared_ptr. At least C++ programmers tend to know that memory
must be managed, while newbies in other languages are often lead to
believe - wrongly - that the garbage collector takes care of
everything.

Dereferencing invalid pointers however is indeed a more serious
problem. This is the one lesson I had in mind when I wrote my previous
message; newbies that are not hopeless tend to learn it rather quickly
and the number of mistakes of this kind they make tends to fall in a
rather short time. I do admit however that even experienced
programmers make similar errors every now and again.

While attempting to dereference a null reference is a rather common
mistake in languages such as Java and C# - I'm not sure about Python -
the one invaluable guarantee provided by the garbage collector is the
absence of *invalid* references. This is one of the reasons why
there's an ongoing effort to add garbage collection to the C++
standard, albeit in an optional form.

Cheers,
Nicola Musatti

Feb 21 '08 #8
Bruno Desthuilliers wrote:
Carl Banks a écrit :
>On Feb 20, 8:58 am, Tim Chase <python.l...@ti m.thechases.com wrote:
>>>You Used Python to Write WHAT?
http://www.cio.com/article/185350
"""
Furthermore , the power and expressivity that Python offers means
that it may require more skilled developers.
[...down to the summary...]
Python may not be an appropriate choice if you:
[...]
* Rely on teams of less-experienced programmers. These
developers may benefit from the wider availability of training
for languages like Java and are less likely to make mistakes with
a compile-time, type-checked language.
"""
(snip)
>>
C++ is a compile-time, type-checked language, which means it is
totally safer for newbies than Python. Yep, your big company is
totally safe with newbie C++ programmers.

Mouarf ! Brillant demonstration, thanks Carl !-)

(and BTW, +1 QOTW)

NB: This is not a troll. (Please, nobody try to be cute with a "yes it
is" reply.)

c.l.python seem to be about the most close-minded of any of the
currently popular language-specific news groups. It's just taken for
granted that Perl and C++, two of my personal favorite things in this
world, inherently favor ugly, buggy code. That is the farthest thing
from the truth as I see it. You can (and plenty of people will) write
terrible code in any language, including Python.

To use Python effectively, you have to know something about how it
works, and the same is true of Perl and C++. But a newbie who's
learning from a decent source (avoid the "C++ for Morons" style books)
is likely (I contend) to be writing semi-useful programs about as fast
as with Python, and to be writing heavy-duty work-horse programs far sooner.

Perl is, and always has been, a language for getting your job done; when
everything else failed, Perl and C++ got me through some of the toughest
tasks of my life. Translating file formats, automating system-level
tasks... And now that the C++ standard library is getting regular
expressions, I can replace plenty of glued-together scripts with
single-language, cohesive applications.

I like Python, and I think it's got a brilliant future ahead of it. It
is rapidly becoming the dynamic language of choice, especially for C++
projects. I am glad that Python can be extended straightforward ly in
any C-linkable language. But this bashing of other powerful languages
on the basis that they're hard to read and hard to use correctly is,
frankly, nonsense.
Feb 21 '08 #9
Paul Boddie wrote:
On 21 Feb, 19:22, Nicola Musatti <nicola.musa... @gmail.comwrote :
>On Feb 21, 6:31 pm, Paul Boddie <p...@boddie.or g.ukwrote:
[...]
>>The main reason why C++ has declined in usage is because almost
everything of practical value is optional.
The main reason why C++ has declined in usage is because it never got
the kind of corporate marketing enjoyed by Java and C#.
No, the real problem is that C++ is the only major language to
have hiding ("abstractio n") without memory safety. C has neither hiding
nor safety. Python, Java, Modula 3, Delphi, Ruby, C#, and Ada have hiding
with safety. Javascript, Perl, and LISP have safety without hiding. C++
stands alone as having hiding without safety, the least safe possibility.

The safety problems with C++ could be fixed, but the C++ committee
is off in template la-la land, ignoring safety issues in favor of
cute template features no one will use in production code.

This has nothing to do with language efficiency or whether the
language is interpreted. Of the languages listed with both hiding
and safety, Ada and Modula 3 are always compiled to hard machine code,
and Java can be. (GCC offers that option.)

John Nagle
Feb 21 '08 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.