Re: Is python worth learning as a second language?



ZikO a écrit :
Hi

I hope I won't sound trivial with asking my question.

I am a C++ programmer and I am thinking of learning something else because I know second language might be very helpful somehow.

Indeed. FWIW, I use about four programming languages on a daily basis - plus "non-programming languages" like SQL, CSS, (x)HTML etc, know at least four others enough to be able to read code and do simple maintainance, and have been studying (at least enough to get a general feel and have a general understanding) half a dozen other languages.

Learning a new languages serves two purposes:
1/ add another tool to your toolbox, so you have the right tool for the job (I definitively wouldn't use C++ for web programming or sysadmin scripting)
2/ learn new concepts and idioms (and this can be invaluable, at least if you hope to become a better programmer).

I have heard a few positive things about Python but I have never writen any single line in python so I do not know this language at all.

Quite a lot of Python users come from other languages - mainly C, C++, Java and Lisp, and these last times from PHP too thanks to Django.

If you're already an experimented programmer, specially from a C/C++ background, getting started with Python should be really easy. I guess your main problem will be the mental adjustement needed to work *with* the language instead of fighting *against* it.

Do you think python would be good complementary language for C++?

Quite a few C++ programmers here seems to think it's the case.

Do you think it's worth learning it or let's say try Java?

Java being mostly a stripped down version version of C++, and not being usable as a glue or scripting language, I don't think you'd get any benefices from learning it.

and how difficult it would be for me if I know C++ pretty well I would say?

cf above. As I said, the hard part will be to stop trying to forcefit C++ concepts and idioms in Python - as usual when learning a somewhat different language. FWIW, learning Python 101 is a matter of days, but it took me months to get rid of the declarative-static-typing / defensive-programming mental straightjacket. Seems like some never get past this point...

HTH
.



Relevant Pages

  • Re: Python or PHP?
    ... If it's one of the things for which Python ... every language here and there more ways to do something. ... you make Perl more complicated than it is:-D. ... Not the programmer. ...
    (comp.lang.python)
  • Re: Python or PHP?
    ... >> every language here and there more ways to do something. ... The best the programmer can do, as you imply, is to ... I am curious of a list of extraneous methods in Perl (more about the ... I just had a glance on Python, ...
    (comp.lang.python)
  • Re: How to actually write a program?
    ... > language I have worked on after a bit of BASIC). ... For a total novice, get one of the tutorial books (e.g., "Learning ... Python" or "The Quick Python Book") and follow through a few of the ... You may want to factor out the "model" and "controller" ...
    (comp.lang.python)
  • Re: OT: Should I learn bash/C/python/perl/other
    ... my grandma had me call my uncle since he was a programmer ... my suggestion here would be to find a language that will do ... >>and I still want to give one more suggestion. ... > or two to start learning C. ...
    (Fedora)
  • (OT)Re: To C or not to C, that is the question...
    ... modifying source code of Linux applications, ... "The C Programming Language" ... Python so if you became comfortable in Python you will be able to do ... statement that someone could be an adequate C programmer ...
    (comp.lang.c)