Live data from Hacker News

Python overtakes Java to become the second-most popular programming language

techrepublic.com

201–210 of 357 posts

Re: Python overtakes Java to become the second-most popular programming language

#201
post #142

Earlier quoted context omitted.

This precise struggle is why Go is created, and also why Rob Pike said what he said. The industry needs a statically typed language with good ergonomics (not typing too much) and performant. I agree with you, asking everyone to be discipline with their code in a dynamic language is a bit too much to ask (unfortunately).

If there is something similar with Django on golang ecosystem, I would use golang more. Battery-included web framework seem to be out of style these days and no one invest in developing one for newer language like golang. As a single developer working mostly alone, microservice-based development is quite painful.

Not sure about golang but D language has a battery included web framework based on the excellent vibe.d [1].

Fun fact, D language forum website is probably one of the fastest and the most responsive websites on the planet [2], and it's written in D but not based on vibe.d or Diamond [3].

[1] https://code.dlang.org/packages/diamond

[2] https://news.ycombinator.com/item?id=16731302

[3] https://news.ycombinator.com/item?id=3592769

Re: Python overtakes Java to become the second-most popular programming language

#202

I was a total raving Python evangelist for the first 12 years of my coding career, and then got a job as the CTO for a Python based startup that had been running absent a technical leader for 5 years, with relatively junior coders making all the decisions. I still love Python, but I now have a completely different attitude to hyper-dynamic languages (like Python, Ruby, Clojure, Elixir, etc). In my new opinion, they a…

I've often found that starting some quick-and-dirty thing in shell scripts is great, but once I get to around 100 lines of shell script code, I'm better off switching to python (or similar). Similarly, once I get to around 1000 lines of python code, I'm better off switching to compiled, statically typed language (e.g., Java, C, C++, etc.). So my own heuristic has become: shell script when

I feel that Python has (among many, many other things) replaced Matlab and the likes.

These were the go-to "prototyping" languages people in science, R&D, etc. used (and still use!), and then you'd port those into more manageable languages for larger scale projects, or actual software products.

These days, Python does all that. Unless you need some extreme performance for your final product, a well-optimized Python program will work just fine.

But still, there's some of that matlab legacy left - instead of one comprehensive application, you have tons of smaller programs floating around, for one-off/single-issue uses.

Re: Python overtakes Java to become the second-most popular programming language

#203
post #127

Earlier quoted context omitted.

> I'm writing some Java at the moment for an Android app, and it's just killing me after doing Scheme and Python Android isn't Java though. It's some frankenstein contraption made from a mutated version of Java from a decade ago. > I were starting my own business now, I'd use Clojure or Scala. I personally wouldn't ever choose Scala for anything. It's tooling is horrible (Sbt is a special hell, and scalac is as slow…

Interesting, I've only read Scala. Personally I like Clojure but thought I should mention it as I see businesses mixing Scala with Java successfully in my work.

You can, but interoperability is not that great. It can work, but often it takes a lot of massaging/converting even basic data types.

Kotlin has wayyy better interoperability with Java

Re: Python overtakes Java to become the second-most popular programming language

#204
post #163

Earlier quoted context omitted.

Yeah, I hear you. Nowadays I do Scheme embedded in C/C++. The stuff I used to love Python for is now done in Scheme, and the outer containers are in C++. It's actually a really nice way to write code, for me at least. Forces a clean architecture on you, and you know you can always move anything out into C++ if you need either a library or lower-level access. I use S7, but you could use Guile, Gambit, Chicken similarl…

This is an interesting architecture, can you provide some more details on how exactly that works? E.g. do you use a c++ library that interprets scheme?

yeah, I use S7 Scheme. It's a complete scheme interpreter in one C file, super easy to embed, quite similar to Clojure linguistically. Basically all "business" logic is in Scheme, all OS/UI interaction is in C or C++. For me, it's amazing, because I write music apps and I can reuse my model code across desktop, phone, in Max/MSP or PureData, in web assembly, everywhere. Being able to prototype in Max is awesome. My model layer only knows about music, the high-level user actions (ie "play note", not "click button"), and Scheme. It doesn't know anything about widgets, phones, etc. All boundaries are crossed with the C FFI layer (which is really nice in S7) forcing a strict ports-and-adapters approach. There absolutely is upfront cost, but the liberation of being totally decoupled from any framework or vendor in my model code is awesome. I chose S7 because I'm doing music, but you could do similar with Guile, Chicken, Gambit, Embedded Common Lisp, etc. And Scheme is so minimal that if I needed to switch Scheme implementations it would not be a big deal - I would only be rewriting the adapter layer.

Interesting, one of the most successful companies I've seen in my tech due diligence work was doing the same thing in high end scientific computing. They had written their own DSL, and a whole containing application layer in C that could run on any target platform, with GUI adapters for windows, unix, osx, etc. They were doing very well. And they could get amazing scientists to work for them super-productively because the DSL was designed around the scientists needs.

Re: Python overtakes Java to become the second-most popular programming language

#205

When I worked at Yelp circa 2013, we were an entirely Python shop (for backend). At that time, we had millions of LOC in Python. I love Python to death, but it became very clear that Python was simply a very bad fit for a project as large as Yelp. I remember trying to write a program to simply understand our dependency graph so we could decouple some of our services (we were just starting our SOA efforts at that time…

Your description here is often the same argument for microservices over a justification for any specific language.

Re: Python overtakes Java to become the second-most popular programming language

#206

I was a Python dev for 14 years or so (now doing mostly personal projects in C/C++, Scheme, Clojure), and 10 years ago met my partner who is a biologist. I think one thing programmers underestimate is how many scientists and academics are using Python. It's not just ML, it's pretty much every kind of scientist and tons of non-science academics too. The fact that it's a great "casual" or part-time language is huge for…

Ya, I think it's great that Python has become a sorts of universal / unified language these days. When I was a student, people used a bunch of different languages to write software, depending on what group they were in, or what the culture there was.

You had Matlab, R, Octave, Java, C++, Lisp, etc. all depending on what type of scientist or engineers you worked with (Statisticians used R/SPSS/etc., Physicists and Electrical Engineers used Matlab or C++, Computer Scientists used Lisp etc., and the list goes on)

At least today, most is written in Python - only the libraries are different.

Also, sharing code is a breeze today. Back then you'd have to download or manually transfer the codebase from other users, check dependencies, install software, check licensing, and what not.

Today you can fire up a Python notebook, and that's it - very nice for smaller stuff. Even larger applications is a easy as pie.

Re: Python overtakes Java to become the second-most popular programming language

#207

I was a total raving Python evangelist for the first 12 years of my coding career, and then got a job as the CTO for a Python based startup that had been running absent a technical leader for 5 years, with relatively junior coders making all the decisions. I still love Python, but I now have a completely different attitude to hyper-dynamic languages (like Python, Ruby, Clojure, Elixir, etc). In my new opinion, they a…

[deleted]

Re: Python overtakes Java to become the second-most popular programming language

#208
post #7

The past month I have used Python again after a few years and I have to say I didn't quite like the experience as much as before. On one hand I also used vanilla Python instead of something easier to use like Django but the amount of preventable run-time errors and the lack of IDE autocomplete support at various points was kind of off-putting after coming back from very strictly typed languages like Swift, Kotlin or…

> The past month I have used Python again after a few years and I have to say I didn't quite like the experience as much as before.

Python is really a Perl replacement. It was meant for the scripting world, not software development - pretty much stuff that was too complex or cumbersome to do in bash.

Re: Python overtakes Java to become the second-most popular programming language

#209

Earlier quoted context omitted.

IMO I doubt switching language would help. It's the same for any language. You can learn to code easy, but learning to write good code/architecture + working together in a large team is really hard.. takes lots of experience and time till the team can come together.

Some languages and frameworks have the right defaults for scale. Rails has a lot of magic that gets you running fast but it doesn't even have a service layer - and instead promotes the abomination that is mixins (concerns), fat models, fat controllers - stuff that gets you running with minimal effort but then crying over the code duplication all over the place and lack of logical separation. ASP.NET is more verbose o…

+1. Every time we look at Ruby app in my tech diligence work, we wind up talking with them about how they wish they had that service layer and weren't doing Active Record methods from controllers. It's a real achilles heel of RoR once things get big.
Post reply on HN