8 ms·
How I decide between many programming languages
- kenhwang 7y agoMan, if one of Go's pros is "good package manager", I'd hate to see what terrible package managers he's experienced. Seems weird to call out Java package management as a con in comparison. I love Scala's type system, though, I suppose if I didn't have a very good CS degree I'd hate it. I think it strikes a good balance between powerful and usable.
- 1ba9115454 7y agoJava doesn't come with a package manager out of the box so most projects seem to go with Maven. If you've tried to understand a project with multiple pom.xml's then for me putting it in the con is a good call.
- dotdi 7y agoWhile this is true, it's not an inherent problem of maven, it's an inherent problem of dependency management is f*cking difficult™.
- coldtea 7y agoMaven is inherently bad too, though
- edejong 7y agoIn which way exactly? Having worked with many, many different package managers, I've come to appreciate Maven's way of doing things. Even though it has many drawbacks: - XML structure is verbose - Plugin architecture makes standard behaviour opaque - Default HTTP with no package signatures is recipe for security problems - "Stages" seem arbitrary and it's not always clear which stages are performed. - Community seems to move to newer systems such as Gradle (and SBT for Scala). But, there are also strengths. The configuration format can be extended easily using the plugin architecture. This provides a huge opportunity to extend the functionality. It is battle hardened over time, which means it is very stable and it has a huge plugin architecture.
- coldtea 7y agoWell, I think you've covered the issues I was going to mention!
- mister_hn 7y agoand Maven is super bloated due to too many downloaded dependencies. An Hello World example with Maven can download up to 50MB of plugins and useless things
- type0 7y agoScala's type system is it strength not a con, actually it is very beginner friendly just not in the way Drew thinks, it's just more high level, By that definition he could also call Clojure a Java derivative because it runs on JVM.
- hans1729 7y ago> Haskell and every other functional-oriented programming language in its class, such as elixir, erlang, most lisps, even if they resent being lumped together Was nice talking to you, have a good day mate
- tannhaeuser 7y agoWhile a useful and entertaining comparison, I feel like a major difference is between "unicorn" languages (languages having only a single implementation and runtime/ecosystem) vs. standardized languages having multiple compilers/implementations such as C and JS (and LISP), though people are throwing JS's advantage of being standardized and one of the must ubiquitous languages around away by choosing not-quite-JS languages such as TS and coffescript before that as the first thing when they're about to start a project).
- undecisive 7y agoInteresting! I'd have put PHP and C++ at the very top of the list, then reverse the whole list. As a rule, I'd much rather start with a language that makes it easy to spot massive vulnerabilities, and then move towards a speedier and more volatile language where needed.
- Hitton 7y ago>I'd have put PHP and C++ at the very top of the list, then reverse the whole list. I know what you probably meant, but if you put them at the very top of the list and then reverse it whole, they'll end up at the bottom again. Just saying.
- undecisive 7y agoNo, that's exactly what I meant! I find PHP to be a bag of confused inconsistencies thrown together. While I have no disrespect to the people who put up with this on a daily basis, I'd never choose it for a new project. Similarly, C++ has never really appealed to me - its idea of OO seems misconceived, and it doesn't seem necessary - my current favourite for this niche is Nim
- keldaris 7y agoThankfully, there's nothing mandatory about OO in C++. I mostly just use C++ as an incremental improvement over C - not "C with classes", but C with constexpr, a bit more type safety and a few other niceties. Nim is better in some ways, but often not really an option for me.
- moksly 7y agoIt’s under the “I don’t like line”, but I came away from this feeling like I should look into Ruby.
- test1235 7y agoAll the jobs which recruiters send me all day long seems to tell me to look into ruby. Or do loads of people start projects in ruby, then leave for something else?
- sundayedition 7y agoI don't see quite as many ruby jobs today but they're still out there. Ruby has been very focused on increasing performance the past few years. A few major teams ran away from Rails because it's really easy to build functional things in Rails that won't scale, which gets attributed back to Ruby performance. I think that was enough to scare people away from using ruby at all GitHub and Shopify both use Rails, among many others.
- keldaris 7y agoThe list may be entertaining, but displays little in the way of objectivity. For instance, OOP is a major con of C++ (even though many people write C++ all day without any of it) but isn't even mentioned with regards to Java and C#? Really?
- maggit 7y agoSimilarly, only Rust has "non-standardized, only one meaningful implementation" listed as a con, even if this is true for several of the others as well.
- mehrdadn 7y ago> OOP is a major con of C++ Not sure what exactly you mean by this, but many people use classes and objects all the time in C++, and see it as a pro rather than a con.
- keldaris 7y agoI was quoting the original article, not expressing an opinion on OOP.
- mehrdadn 7y agoOh shoot, sorry for the confusion. I guess that's a sign I need to go to sleep...
- antoinealb 7y agoThe linked article is listing OOP as a con of C++ without justification. I think that is what the GP is referring to, rather than stating their own opinion.
- koen_hendriks 7y ago"every PHP programmer is bad at programming, the language is designed to accommodate them with convenient footguns (or faceguns) at every step, and the ecosystem is accordingly bad. No, PHP7 doesn’t fix this. Use a real programming language, jerk." This guy seems like a real open minded person who did his research and shared his opinion after making strong points. /s
- arez 7y agoyep, stopped reading after this. How can this be objective if you think that everyone is a "bad" programmer that uses this or that language, wtf. Pros for PHP could be, it's templating capabilities with HTML, easy to use DB interfaces and the entanglement with the web/HTML/web-server in general. Nowadays you don't really write these kinds of apps anymore where your backend returns whole HTML Pages but that doesn't mean it's a bad language.
- jesterson 7y agoSame. Also I'd add low entry barrier and maturity of interpreter. Of course, this comes at a price. But saying PHP has no pros is quite subjective
- ncphillips 7y agoCalling it “subjective” is being pretty nice. It’s just an obviously incorrect statement.
- krapp 7y ago> How can this be objective if you think that everyone is a "bad" programmer that uses this or that language, wtf. I get the feeling the author is either not trying to be objective, or is one of those people who confuses strident opinion for objective fact. "PHP is bad and everyone who uses it is bad" is a meme that some people take seriously... and one that also applied to javascript until Node.js appeared and it became valuable, interestingly enough. I would say there are no objectively bad languages, just bad code (which can be written in any language), or languages which aren't used in an optimal way, since every one was created with a specific frame of mind and intended use case. PHP serves its purpose, and if someone doesn't want to use it, they can just not use it. Obviously PHP has pros, if it didn't, no one would use it.
- salex89 7y agoWhat's the issue with Java package management? If that's a Java con, what should be said about Python's?
- Traubenfuchs 7y agoIs there any wide-spread language with a better package/library management than maven?
- probablybroken 7y agoStrange that the availability of developers who can actually be recruited for the given languages isn't listed as a factor.
- Tomte 7y agoHe's a one-man-shop. Hiring doesn't matter under those circumstances.
- peterkelly 7y agoAny programmer worth their salt should be able to adapt to a new language when they start at a new project/company. Hiring processes that target people who know language X are just dumb, except for very short-term/time sensitive work.
- type0 7y agoSeems like a lot of corporate environment has settled on: "We hire programmers that can use myriad of different languages (except Lisp off course, no one want's to deal with Lisp) and then you also have to know Java because in fallback situation you'd be useless in their time constraint setting //goodbye" that kind of thing, did I get this wrong?
- probablybroken 7y agoIt's true that good developers can learn new things, but it can take years to learn the frameworks and ecosystems. I've seen projects fail due to a lack of skilled developers & having to either recruit contractors, or developers without the relevant background. Being a developer on one of these teams can be a real nightmare.
- TurboHaskal 7y agoSadly, hiring managers do not agree.
- taivokasper 7y agoIt seems Drew DeVault is highly opinionated and the opinions are more than 10 years old.
- majewsky 7y agoDrew is also one of the most insanely productive programmers currently, serving as lead developer of Sway, wlroots and SourceHut and as CEO of sr.ht.
- TurboHaskal 7y agoWhile I like and use his work, I do think there are hundreds of thousands of programmers out there that are as productive and have as much impact, just that they don't happen to do open source.
- elcritch 7y agoBemusing, though lumping all functional languages together makes me balk a bit. There’s a big difference between static and dynamic functional languages. Haskell and Ocaml have a different feel than lisps/Elixir/Erlang with the latter group being much more practical in state management imho.
- hans1729 7y agoI mean, he lists "functional" as a pro and a con, using a fancy font for emphasis. Like another commenter posted: guy seems very opinionated, but his article lacks any profound stance on... anything? Oof
- haspok 7y ago"C ... statically typed" C is just an assembler with macros, so I think this is a bold statement... "Haskell and every other functional-oriented programming language in its class, such as elixir, erlang, most lisps, even if they resent being lumped together" The set of problems I would try to solve in Haskell and the set of problems I would try to solve in Erlang are disjunct. And its not just about the language, it is the whole ecosystem around it. "Scala ... Java derivative" ??? I'm not sure if this post was an attempt of some kind of humour or not.
- tom_mellior 7y ago> C is just an assembler with macros No. Can we put this dumb meme to rest? 1972 C was just an assembler with macros. 2019 C has been a major focus of highly complex compiler research and engineering for decades. Sure, if you write broken code, C will happily access illegal memory if that's what the input program tells it to. But it will do so efficiently ;-)
- TurboHaskal 7y agoI have tinkered with dozens of languages, yet, when I can choose a programming language and money is on the line, I always ask the following questions: - Does it have a standard and a good track record for backwards compatibility? - Is it memory safe? (Bound checking, no pointer arithmetic, etc.) - Does the runtime have automatic memory management in the form of a tracing GC? How tweakable is it? - Does it have kernel thread support? - Does it have a centralized package repository? - If typed, will the type system assist me in defining the business domain? Does it have type inference? - If dynamic, will the development experience allow me to experiment, inspect and redefine stuff at runtime? - Can I distribute my programs as a binary or dump everything onto an image? - Can I go low level when it matters? How's the FFI experience and overhead? - Does it run on the major operating systems? Things I don't care about: Syntax, static vs dynamic typing / OOP vs FP religious wars, community size or "niceness", library count, logos, on-boarding experience aka the possibility of hiring cheap juniors. Cute mascots are nice though. We need more of that.
- tom_mellior 7y agoWhat answers do you come up with for these questions?
- TurboHaskal 7y agoNo perfect answer yet but I am mostly programming in Go and Common Lisp these days. I am looking forward to multicore OCaml and maybe I give F# a go.
- siempreb 7y ago> C++ > Pros: none > Cons: ill-defined, far too big, Object Oriented Programming, loads of baggage, ecosystem that buys into its crap, enjoyed by bad programmers. This is just rubbish. Fair chance the author wrote this with the help of C++ (your OS or browser maybe?). And I enjoy C++ and it's eco system as well, compared to other languages. So that makes me a bad programmer? I'm surprised people are taking this post serious.
- actimia 7y ago'there is widely used software written in language x' != 'language x is good' C++ definitely has its uses (and for a long time was best-in-class for many of them) but it is largely being superseded by other options (not necessarily Rust).
- xiphias2 7y agoJust as an example it's really hard for me to do low level CUDA GPU programming in any other language. I'm trying hard to use Julia, but understanding its PTX output is really hard for me, and also I don't know how to use the matrix multiplying GPU instructions. Rust's PTX output is not supported, so I haven't really tried it.
- coldtea 7y ago>Fair chance the author wrote this with the help of C++ (your OS or browser maybe?) Which OS would that be? Most OSes hardly touch C++, except at higher layers than the kernel.
- ziotom78 7y agoI agree. Given that I do not like C++ and try to avoid it at all costs, it is unfair to say it does not have any advantage: - It is available on a very wide range of platforms - Several implementations are available - It is updated regularly - Etc.
- dathinab 7y agoHonestly most people I meet in real life (so not representing at all) who enjoyed C++ where technically skilled but had to fight with following problems: - bad at keeping code simple - to much focused on details instead of the broader picture - bad as team leads due to missing some relevant management skills - bad at producing solutions which where "just good enough" (instead of perfect) Some of them where aware of their weakness and learned to improve on that areas, setting them on a path of becoming excellent software engineers. Others where obvious about it or even in denial about it. In a certain way they had been examples about how a person can be both a technical skilled programmer, as well as as bad programmer who on a subtile way accidentally makes it hard to produce a good end product in any reasonable amount of time.
- pjmlp 7y agoEasy. The main platform language used by the target platform requested by the customer.
- dotdi 7y agoLook, I'm wary of negative comments on HN myself, but this is just a bunch of <Language I know way too little about>: <Simplistic or incorrect summary of a few blog posts I saw a while ago>
- bctnry 7y agoOne rule of thumb that's worth following is to never waste your time reading blogpost like this. If you ever saw a blogpost structured like this, just close the tab.
- fanpuns 7y agoI thought this list was hilarious (despite some of my preferred languages being on the never use list). I'm surprised to see so many people taking it so personally/serious. If this list really offends you, I would suggest you haven't been programming very long, you don't know many other languages (than the ones on the shit list), or both. Maybe the list is a little hyperbolic, but didn't you pick up on the tone?
- mobilemidget 7y agonice read, could maybe use a section, when to decide not to use any programming language, but just available system tools
- agumonkey 7y agothat's one tiny tiny benefit of classical OO, so many languages shared very similar constructs, you could think in "UML" (cough) and not worry about the language per se.
- sundayedition 7y agoAmong the other criticisms, Ruby hasn't been hip for a while. Bootcamps started offering nodejs, meetups are more diverse, fewer conference topics on Ruby. One major local conference had such low attendence last year they were going to cancel it this year. It's a very low quality post.
- sundayedition 7y agoI didn't mean this as a criticism of Ruby, either. I'm a Ruby/Rails dev and still enjoy the language, even if it feels like it's fallen out of favor
- karmakaze 7y agoTL;DR Post: How I decide between many programming languages Pros: Unintended humour Cons: waste of time, exceedingly bad example of anything technical
- cafard 7y agoUnintended?
- dathinab 7y agoI respect this person a lot for the person's C programming skill, and open source involvement but I have to say I often end up disagreeing with his opinions about more "complex" languages.