Is Python the future?

  1. Is Python the future??

    I know currently in the sciences and physics especially, C++ is the language of choice. It is like this in my department, and looks to be that way everywhere else. However, in the computer science department, they don't even offer programming classes taught in C anymore, just python and scheme. So far, I have learned C++ while doing research, and python from a class. I know how powerful and universal C++ is, but python is so much more enjoyable to program in, because it is so much easier to read.

    Every undergrad physicist I've talked to about this agrees with me that python is much more fun than C++. Do you think that someday python will slowly overtake C++, and will be a good idea to stay familiar with python (even if I don't have to use it everyday)? Sort of like what happened with C++ overtaking fortran once a new generation moved in.
  2. jcsd
  3. Re: Is Python the future??

    Though I'm not a professional on the topic, I have postulated a similar question to my professors.

    They responded that python does not allow for the same amount of management of system resources, and python is an interpreted language and not compiled directly to machine code which has performance implications.

    Maybe a more educated user on both languages can further this point for you.


    EDIT: This doesn't belittle the importance of python, however, I know it is preferential to c++ for smaller projects and is used for scripting along with LUA for existing applications developed in C++.
  4. D H

    Staff: Mentor

    Re: Is Python the future??

    Python is a nice scripting language. Far, far nicer than shell scripting, nicer than perl for the most part. But if there's any extensive string processing involving regular expressions I'll choose perl, hands down. My perl code is portable. The corresponding python code isn't. Who knows what version of python some other installation is using?

    The python community did some damage to itself with their constant mods to the language and with python 3 in particular. One installation I use still has python 2.4, another has 2.6, yet another, 2.7. One installation got their users very POed by switching to python 3. They switched back.

    The intransigent views of van Rossum and the rest of the pythonistas (NO BRACES!, forced indentation (beware tabs in a script handed to you, woe to the blind person who wants to use python, self-executing code has to be properly indented in the current indentation context), there's only one way to do it, ...) gets in my way of adopting the language with open arms. I really like some parts of the language, like some parts, but there are some aspects of the language that I just do not like at all. At least the descriptive phrase isn't "loathe" any more. Except for lack of declarations. That one still falls into the "loathe" category.
  5. Pythagorean

    Pythagorean 4,483
    Gold Member

    Re: Is Python the future??

    Many of the neat things about python that make it convenient, I can do in matlab, which has much better support for developing GUIs imo. It's hard to mix tkinter and matplotlib to do the things that matlab makes easy; wxPython and matplotlib seem to have the same problem. (note, matlab now fully supports object oriented programming, including class definitions and inheritance)

    That being said, python will always been an appealing concept that makes coding intuitive and quick, and is ultimately more of a programming language than matlab.

    I think I will learn C/C++ before I learn python. Python's more of a long-term project.
  6. D H

    Staff: Mentor

    Re: Is Python the future??

    One other benefit: Python is free. Matlab costs, and a whole lot. A python module that does just what you want: It's free, too. The matlab toolbox that does just what you want might cost more than matlab itself.
  7. Pythagorean

    Pythagorean 4,483
    Gold Member

    Re: Is Python the future??

    Yes. It's increasingly frustrating how many cool things matlab can do... if only you'll buy the appropriate toolbox not included with your license. I'm still miffed that the symbolic toolbox isn't part of the standard library.
  8. Re: Is Python the future??

    I for one think that in a hundred years we'll be able to program in english. Computers are getting smarter, and it seems reasonable to think that in the future we won't need programming languages. We'll be able to give a computer an instruction in english or some other natural human language and it'll be able to carry it out.
  9. Pythagorean

    Pythagorean 4,483
    Gold Member

    Re: Is Python the future??

    Computers aren't smart at all; people are being more clever about how they design computers. There's a whole world of information in 'context' that computers have no hint of ever being able to pick up on. That's the root of the language problem.
  10. AlephZero

    AlephZero 7,248
    Science Advisor
    Homework Helper

    Re: Is Python the future??

    Actually we have been going the opposite way for the last 50 years or so.

    The inventor(s) of COBOL thought the way to make programs easy to understand was to write out in full "MULTIPLY A BY B GIVING C" rather than cryptic stuff like "C = A*B".

    Thankfully, almost almost everybody since has disagreed with that bright idea!
  11. Re: Is Python the future??

    In terms of applications, there will always be specialized platforms used in the design and execution of specialized programs and runtime environments.

    Because of this, there will always be a wide variety of platforms that each have their advantages and disadvantages.
  12. Re: Is Python the future??

    I agree with all of what people say above. And you can only compare the two languages in some particular aspects.
    I think CS schools prefer C++ because it is not only more useful in physics and sciences in general but it is a representative for currently most used languages together with its widely known concepts/paradigm such as OOP and meta-programming. In the past people should have looked into SmallTalk, Pascal, LISP, C etc. What programs did you make that become enjoyable in Python ?
    Code readability depends on your knowledge of the code constructs describing the program workflow under consideration and also depends upon your like of the language of choice. Python offers more user-friendly interactive capabilities. Personally, I also enjoy myself pretty much with web libraries such as Django and Twisted since they offer me chances to write my own webserver to run my web application in within. I won't find it strange at all if one day some certain languages take over C++ or Python. It simply to me is just a normal progressive transition as what it is happening now to previous SmallTalk, Pascal and C. Yet, software development methodology such as OOA, OOD, OOP, AOP, SOA, Agile Driven Development etc will always remain.
Know someone interested in this topic? Share this thead via email, Google+, Twitter, or Facebook

Have something to add?