Follow Slashdot stories on Twitter

 



Forgot your password?
typodupeerror
×
Python Java

Python Finally Ties With Java In RedMonk's New Programming Language Rankings (zdnet.com) 90

An anonymous reader quotes ZDNet: Python is tying with Java as the second most popular programming language behind JavaScript, according to developer analyst RedMonk's latest ranking.

The second spot for Python is the highest position it's ever attained in RedMonk's list of top programming languages, which is based on an analysis of GitHub and Stack Overflow data. Historically, Python has been steady in fourth position but it rose to third spot three years ago in RedMonk's tables... Python has been rising across several programming language popularity indexes, including Tiobe and IEEE Spectrum.

Microsoft-maintained TypeScript for large-scale JavaScript projects has also risen one place to ninth position along with C... Rust is a popular language among developers who discuss technical challenges on StackOverflow, but it hasn't moved from its spot at 21.

This discussion has been archived. No new comments can be posted.

Python Finally Ties With Java In RedMonk's New Programming Language Rankings

Comments Filter:
  • by phantomfive ( 622387 ) on Saturday March 07, 2020 @06:38PM (#59806824) Journal
    Java and Python. Both popular for the same reason: not because they are good, but because they were used in school to teach new programmers.

    Java: the COBOL of a new generation.
    Python: the BASIC of a new generation.
    • Java and Python. Both popular for the same reason: not because they are good, but because they were used in school to teach new programmers. Java: the COBOL of a new generation. Python: the BASIC of a new generation.

      I'm not disagreeing with you, but I'm curious: what language(s) DO you like?

      • by blue41 ( 6654018 )
        What is your advice ?
      • by phantomfive ( 622387 ) on Saturday March 07, 2020 @07:02PM (#59806856) Journal
        C, TCL, Smalltalk, Objective-C, Erlang, Perl, Lisp, Ruby. (Java is ok if you're working with a bunch of semi-competent programmers, because they won't mess up the codebase too bad. Whereas I see no benefit at all of Python over other languages: it has a "clean" look, but that comes at a cost).

        Most languages these days are actually acceptable (I still hate them), we've moved beyond the pains of SNOBOL or BASIC where the only control structures were "if" and "goto".

        The real thing we are lacking is a language that has really good organizational primitives (you could say LISP has them, but that's because LISP is just a syntax tree and a preprocessor. It has anything, the challenge is finding what's good). OOP is ok, but you can tell it's not right because it leads people to implementing all kinds of strange design patterns.
      • I knew I forgot one: APL. Great language, well-designed, elegant.
        • I knew I forgot one: APL. Great language, well-designed, elegant.

          A necessary, but not sufficient, condition for being a great language is being useful for software development.

          The best measure of that is to see how many projects are actually implemented in the language.

          APL fails that test. It doesn't scale beyond about 10 lines.

          • The best measure of that is to see how many projects are actually implemented in the language.

            What on earth made you think that is a good metric?

            • What on earth made you think that is a good metric?

              I don't know. I just think a good programming language should be useful for writing programs.

          • APL fails that test. It doesn't scale beyond about 10 lines.

            btw, this is wrong, APL is clear if you write it well, just like any language.

            The best way to conceptualize APL is basically like R but it can handle more dimensions. R and APL cover the same use case, but APL does it better.

          • Of course with APL you can write any program in 10 (possibly very long) lines or less.
    • by tttonyyy ( 726776 ) on Saturday March 07, 2020 @06:59PM (#59806852) Homepage Journal

      I'm a C coder by trade but I love Python because I can bang out what would be time consuming to code in C in a matter of minutes. Sometimes it's about doing what needs to be done - not how you get there.

      • by phantomfive ( 622387 ) on Saturday March 07, 2020 @07:05PM (#59806860) Journal
        That's about libraries, not about the language. Notice the difference, please. With good libraries, you can be just as efficient in C as in Python, and it's arguably easier to keep your code clean since C actually has real types.
        • C doesn't have near the number of libraries that Python has. It can't even be on the same order of magnitude.

          I shudder to think at how much slower doing Notebooks/Pandas/Matplotlib data exploration would be in C.

          • I shudder to think at how much slower doing Notebooks/Pandas/Matplotlib data exploration would be in C.

            It would be about the same, with the right libraries.

          • C doesn't have near the number of libraries that Python has. It can't even be on the same order of magnitude.

            s/Python/Perl/
            s/C/Python/

            Everything is somewhere on the curve...

            • How are Perl's TensorFlow bindings?

              • You always seem to get stuck on specifics, but the original post was about quantity.

                In any case, a quick Google search found at least one Perl package for TensorFlow client mappings ... https://metacpan.org/pod/AI::P... [metacpan.org] but, in general, who cares. If it's important to you and you find what you need with Python, enjoy, but Python is still younger and has fewer libraries -- in general -- than Perl. It's not a contest, both languages have value.

          • by Uecker ( 1842596 )

            Huh, are you kidding? There exist millions of C libraries. Also data exploration works just fine in C. But I agree that the bare language does not come with a sufficient set useful functionality, and it therefore takes more effort to find the libraries you need. But installing is then usually as easy as 'apt-get install libfoo-dev'.

            But anyway, the proof of the pudding is in the eating, as long as most applications I rely on daily are written in C and not in python, I would say python still has to show its m

          • Python is an interpreted language running in an interpreter written in C. Why do you think that optimized C would be slower than Python which is running on an interpreter written in C?
        • That's about libraries, not about the language. Notice the difference, please. With good libraries, you can be just as efficient in C as in Python, and it's arguably easier to keep your code clean since C actually has real types.

          The language and the libraries are usually not separable.

          With a standard Python installation, you get an incredible array of useful libraries, all installed and ready to go.

          With C, you get to use dangerous string manipulation routines that haven't been improved since the 1970s, and you get to write almost any other nontrivial container yourself from scratch. (Unless you decide go down some reference counting hellhole like Glib.) Any higher-level library functionality you've got to track down on your own and

          • The language and the libraries are usually not separable.

            That's a pretty dumb statement.

            Oh, and C is significantly less strongly typed than Python

            And that's an extremely misleading statement, leading me to believe that you can't see clearly for some reason or another, and are purposely presenting facts in a misleading way.

            • Are you some kind of weirdo who enjoys downloading, installing, compiling and linking development libraries? Then repeating the process in an incompatible way for each platform you use?

              My typing statement was not misleading. Python is dynamically typed and strongly typed. C is statically typed and not-at-all strongly typed. It is trivial to completely subvert its typing system, and in many common usage cases (printf, qsort, any variadic function at all, and any scheme to implement polymorphism), that is the

        • It's actually both. If you haven't programmed a real project in Python (or another language that is similarly much higher level than C), I really recommend you try it - take a weekend and put together a meaningful but complete project and you'll really see some huge differences in productivity that come from the language itself.

          There are many similarities to the jump from asm to C - you give up some things and get other things - such as a productivity boost - in return.

          • I program in Python several days a week. It's my job. But you are too dumb to recognize the difference between a language and the libraries. Why do you even talk?
            • I program in Python several days a week. It's my job. But you are too dumb to recognize the difference between a language and the libraries.

              Actually, no, that's not the case at all. Here's a small but real world example from just yesterday; a little snippet of code I wrote in the middle of a larger project, but essentially here's what the requirements were:

              Input:
              - a text file with up to ~100k email addresses, one per line
              - emails are in whatever mixed case users entered them as (they were stripped out of email 'To:' headers)
              - emails are known to be valid, but some are of the form 'user@host.com' while others are of the form 'Some Name <user@

              • You'll also notice that these few lines of code required no additional libraries (third party or otherwise) and that the entire problem was easy to solve because of the language itself, not because of libraries.

                Libraries included with the language are still libraries you dimwit.

                • You'll also notice that these few lines of code required no additional libraries (third party or otherwise) and that the entire problem was easy to solve because of the language itself, not because of libraries.

                  Libraries included with the language are still libraries

                  So? Who said otherwise? My code used builtin language features, and not any builtin libraries. Why is this relevant? Because earlier you (wrongly) asserted that the productivity gains someone was getting were due to libraries and "not the language".

                  you dimwit.

                  Just a heads up: when you behave this way (silly and over the top hostility), to everyone else you come across like this guy: https://screenrant.com/parks-r... [screenrant.com]

                  (if that's your goal, you're pulling it off marvelously; if not, just a friendly FYI that you might want

              • Here's how I would do it. [codepad.org] The essential realization is that everything a programming language does is just calling functions, although that can be hidden by syntax (for example, the BASH shell "ls | sort | tail -1" is just chaining functions but different syntax). I used a grammar because they are cleaner (and easier to prove correctness, if you're into that, which we aren't in this example). (I would have pasted it in the comment but Slashdot complained about the special characters)
                • Cool, thanks for taking the time to make a meaningful reply. I also appreciate that you were able to communicate without resorting to name calling - thank you.

                  For what it's worth, though, I think that example proved my points - more than 3x the code, relatively much more complex implementation, probably took much longer to implement (the Python version, including testing, was about 5 minutes), and likely at least one bug (depending on the behavior of ehash_iter*) and maybe memory leaks (depending on what so

        • Yes, the libraries are very important and I agree the "batteries included" concept is a major part of Pythons success. But, it is more than just the libraries.

          I could perhaps write the first buggy version of the same code in C++ (I haven't done any real C stuff for a very long time) in about the same time as in Python, but testing and getting it bug-free and "right" takes much much longer.

          The edit-compile-test cycle is MUCH faster in Python (IMHO). By default, the compilation units are small (one pyc per py

          • Java never caught on for scientific computing and I'd claim it is because it makes low level interaction hard (not impossible, just hard and messy).

            My sense, talking with scientists who use Python and R for data science, is that they just don't 'get' OOP. And that's understandable. Because OOP is an attempt to make organizing large programs easier (Java especially optimizes for that), and because data scientists are essentially just writing long batch scripts (but with math), they just have no use for it.

            Java isn't really designed for the use case of scientific computing, but Python, as a scripting language, is entirely perfect for writing scripts.

        • by swilver ( 617741 )

          I'll state the contrary. You can't be as efficient in C as you can be in Python, because there is a lot more housekeeping and boilerplate involved in C, even when using libraries.

          • Sometimes that's true, but by "housekeeping" you mean entirely memory management, since for other types of housekeeping Python has to keep track of it too.

            Memory management has two ways of being simplified in C: one is to use a garbage collector (there are a bunch of them), and the other is to use memory pools, cleaning up after every event loop. Actually almost every problem with memory management can be solved using memory pools of some kind, except problems that would also exist in python (and by "pro
        • No amount of libraries can make dealing with strings in C as simple as it is in Python.

          • Nonsense. Python doesn't have a good grammar library.
            • Python has dynamically allocated, garbage-collected strings, with easy concatenation and formatting. That alone means that something as trivial as a+b+c in Python can translate to several lines of C.

              • Nah, you just haven't thought very hard about how to make a good C library.
                • I wrote plenty of C. There's no way to get around tedious manual memory management there. Nor is it unique to strings - it's just that it's particularly glaring in that case compared to, well, pretty much anything else.

                  End result is, so much C code uses fixed-size buffers to keep things simple, and then users wonder why there are arbitrary limits on text length. Or worst case, there aren't enough checks, and then invalid inputs overflow the buffer.

    • by Anonymous Coward

      Not really, Java is popular because it's statically typed, memory managed, and JIT compiled which hits the sweet spot of performance and quality.

      Native compilation is largely outdone by JIT compilation now because JIT compilation can optimise for a specific machine rather than a generic platform - given compilers have been better than hand optimisation for all of like 99.9999% of developers for a long time now then that means there's no performance benefit to native now for the bulk of development. Garbage

      • Re: (Score:2, Flamebait)

        by phantomfive ( 622387 )

        Native compilation is largely outdone by JIT compilation now because JIT compilation can optimise for a specific machine rather than a generic platform

        Keep drinking the cool-aid boy, keep drinking it.

      • Native compilation is not outdone by JIT. Native will always be faster and more efficient; however, RAM measures in GBs and multiple core CPUs available for even the budget computers such optimizations are not necessary. JIT does have portability advantages. In prior decades code on an AMD vs Intel chips might have a performance difference at 200 MHz but not so much running 3GHz with optional overclocking.
        • by Anonymous Coward

          Native compilation is not _always_ outdone by JIT, as I pointed out someone who is good at handcrafting optimised code, the 0.0001% of developers left who can do will indeed be able to produce more performant code.

          But in the general case, yes it is, they were almost level around 10 years ago, and the gap has only widened since. It's not clear why you would believe that native will always be faster when JIT has the significant advantage of being able to optimise at runtime based on real world usage, somethin

          • If think you need to educate yourself on modern JIT compilation technology, as it sounds like your knowledge is somewhere between 10 and 20 years out of date. There's a reason literally everyone has jumped on the JIT bandwagon from JavaScript to PHP; because those runtime optimisations open up significant areas for further optimisation, whilst AOT compilation optimisation is largely stuck in a rut.

            It sounds like you should read what I wrote again as I largely agreed with you but you just assumed my "knowledge is somewhere between 10 and 20 years out of date". In most situations today, native compilation does not gain a significant advantage over JIT. The term is "most" but not all.

            You will never be able to automatically optimise for the details of an unknown execution platform better than something that's actually running on that platform and that can analyse the execution path ways in real world usage can in the long run without making your native code do pretty much the same thing and act as a defacto JIT in the first place.

            You do realize that there are applications in this world that have known execution platforms right? For things like supercomputers which are built using exact hardware, it does matter if you use Native vs JIT as you need ev

    • by AHuxley ( 892839 )
      Ada and Pascal make that list?
      • Not really, I've played with them but not enough to enjoy them. I've heard good things about Delphi, but can't personally comment.
    • No mention of Fortran or Pascal? How did that comment get an Insightful mod?

      When I first saw this story I misinterpreted the headline. I thought it was about a new language named Rankings that finally ties the virtues of Python to Java's strengths. Must be named after that famous programmer? Jeff Rankings, wasn't it? Apple guy?

      I still think it qualifies as a clickbait headline. Programming language wars!

    • by pinjo ( 6672162 )
      Python and java are good generalists, but a bit boring. Personally I like functional programming better, but that is because I work on distributed systems. If I wrote device drivers I probably loved C. Programming languages are just tools in the end. I think such a popularity metric is useless to measure how good a language is. E.g. if we go down that path we could deduct that TCL is superior for hardware design, because it is used there often. Well, that doesn't make sense. What does make sense though, is
    • Java: the COBOL of a new generation.
      Python: the BASIC of a new generation.

      i tend to say python developed for autists who would throw a fit at a perl oneliner on stackoverlords but i have issues ofc ... , yea, i don't know what's so great about it other than the fact that it forces you to do stuff in a certain way, which, to me, makes it absolutely awful , its like the program-police , and also heavy and well , ofc. people should use what they're comfortable with but said people should also not try to shove it up or crawl up my arse , its they who are the triffids - if moore's la

  • by Anonymous Coward
    I see the word "Python" and think it's going to be something about Monty. Sigh.
  • by joe_frisch ( 1366229 ) on Saturday March 07, 2020 @07:18PM (#59806880)

    Different languages are good for doing different things. You don't want Python on an embedded micro-controller where resources are scarce, or in a high reliability application (space, life safety etc). Its horrible at low level hardware interface. OTOH, designing graphical applications from scratch in C is crazy.
    (I know that there are people who will disagree with all of the above)

    There is also a question of whether a language is being used for (often very valid) legacy reasons. If you have a large application suite in Fortran, it may make sense to keep using fortran to develop new components

    • Micropython pretty good for prototyping. You can save a lot of C-boiler plate by re-doing it in just Python.

      For example to probe my ODB on my car this is as much code as is needed:

      from pyb import CAN
      can = CAN(1, CAN.LOOPBACK)
      can.setfilter(0, CAN.LIST16, 0, (123, 124, 125, 126)) # set a filter to receive messages with id=123, 124, 125 and 126
      can.send('message!', 123) # send a message with id 123
      can.recv(0) # receive message on FIFO 0

      I wouldn't be doing ASIL-D hard RTOS timings with it, but

  • by Austerity Empowers ( 669817 ) on Saturday March 07, 2020 @07:24PM (#59806884)

    Why is it important to have a popularity contest with programming languages? Whose interests does this serve? Does this even make the slightest amount of sense?

    There's such a thing as the right tool for a job, and while that decision *might* not be straightforward in all cases, and people in that line of work may have strong opinions, the different number of ways programming languages are used, and by the different demographics and levels of competence and acumen make a broad poll of popularity entirely worthless.

    Also, and this is really important, you can learn new computer languages in a few months, but the industry and technology you are using them FOR is usually more involved. I would start with the line of work, then figure out the options within that line of work and gauge popularity and trends within that line of work next.

    • by znrt ( 2424692 )

      Why is it important to have a popularity contest with programming languages?

      it isn't

      Whose interests does this serve?

      dumb ctos, click baiters and language evangelists, to whom it provides valuable moments of joy, dismay and excitement in varying proportion.

      Does this even make the slightest amount of sense?

      further than providing income/attention/entertainment to those above, no. not really :D
      it's called 'content' nowadays ... \o/

  • And I can't wait for the "Well when I tied an onion to my belt" stories from the gray beards that haven't done anything new in 30 years.

    First off, No one is going to take your toys away. FORTRAN and COBOL still exist, so you can ride off into the sunset with whatever language you picked up when you were young.

    Python's become our lingua franca at work for anything from data analytics to batch processing 'glue'.

    • Whitespace is never an issue. I honestly can't fathom how this many of you have problems with it.
    • Re: (Score:2, Insightful)

      by Anonymous Coward

      Pythons indentation-based syntax is brilliant. I'll even forgive the artificially limited expression syntax and the lack of a real case statement. ... but Python has no useful static typing, which disqualifies it from serious projects. Runtime exceptions are not OK. The big problem with Python that it's so easy to use it for a quick hack or a prototype that people are seduced into using it for serious projects anyway.

      • The big problem with Python that it's so easy to use it for a quick hack or a prototype that people are seduced into using it for serious projects anyway.

        It's better than VBA, which is what you end up with if the only 'programming' environment you give some people is Excel.

        but Python has no useful static typing

        Why does mypy not work for you?

        • "Why does mypy not work for you?"

          Have you actually _used_ mypy? If so, I can't believe you're asking that question. Mypy is a pitiful, tacked on, half assed excuse for static typing.

    • Re:I love Python. (Score:4, Interesting)

      by putaro ( 235078 ) on Saturday March 07, 2020 @09:04PM (#59807048) Journal

      Well, the guys who tied onions to their belt laugh at the kids with their toy projects exclaiming "language X is the greatest thing ever". One criticism of Java I saw was that "you need to read a book to understand it" - I laughed all afternoon. Your facial recognition example is classic - you called a library in three lines. I could do the same thing in Java or C with a few more lines of code. If I want to bang something out that works this afternoon, Python is a great choice. Now, go write that facial recognition library. Python is not going to be your first choice.

      • I could do the same thing in Java or C with a few more lines of code.

        Ok, do it. If there was as easy a library to use then there should be a trivial example from that library you could just copy and paste.

        Now, go write that facial recognition library. Python is not going to be your first choice.

        Why would it be? A hammer makes a terrible screwdriver. Not everything has to be a 'low level' project.

        If I want to bang something out that works this afternoon,

        You're starting to get it. Now imagine a scenario where peoples jobs are to 'bang out' those things in the morning to get work done in the afternoon. Quick dirty data analysis scripts to clean up some logged data. Not every software project has to turn itself into Apache.

    • Re: I love Python. (Score:4, Insightful)

      by astrofurter ( 5464356 ) on Saturday March 07, 2020 @10:54PM (#59807284)

      "gray beards that haven't done anything new in 30 years"

      I first programmed in Python 20 years ago. It's hardly the new shiny. Trust me, when you get to a large application developed over time by many programmers - Python sucks ass. Dynamic typing is a curse.

      • It's a shame no one has developed any useful libraries in those 20 years.

        Python sucks ass.

        A large application developed by many programmers is only specific development methodology. Not everything is a huge project. Not every project needs a dozen people.

    • by nagora ( 177841 )

      And are all your libraries that you're calling written in Python? If not you've not managed to make any coherent point about the language itself. I can call library code from assembler, C, Forth, C++, Rust, whatever. I can probably even do it from Smalltalk and have a proper functional OO language to work in when I get the results back instead of some hacked-together bastard scripting language that doesn't even have proper boolean objects. But then, it's also opted for a "any old shite in any old order" cla

  • by anoncoward69 ( 6496862 ) on Saturday March 07, 2020 @10:00PM (#59807166)
    It's popular because any monkey can do it. Literally with all the libraries 95% of the people are not even coding, they're doing plumbing work shuffling data from one library to the other. The only ones actually "coding" in python are the ones writing the libraries.
    • Having loads of libraries makes it easier to focus on the 'plumbing' rather than creating your own libraries or functions that oftentimes only serve to solve common problems experienced by many other people. I can't tell you how many times I've searched the internet for how to solve a programming logic issue only to find that several other people that have already experienced and solved the exact same issue (which oftentimes involves importing a library). To me, the highest metric by which to judge a progra
  • I've been coding in either C or PHP for most of my life, though I know everything from Assembler to COBOL and have used it at times.

    I recently picked up both Rust and Python and like them both - for different reasons. I like that Python has the PHP ability to run interpreted, which makes it just so much easier to come up with a quick script. The syntax is relatively easy after getting a bit used to tabs being meaningful, but that's not a big hurdle. And there seems to be a library for everything.

    I like Rust

1 Mole = 007 Secret Agents

Working...