What Makes a Programming Language Successful? 1119
danielstoner writes "The article '13 reasons why Ruby, Python and the gang will push Java to die... of old age' makes an interesting analysis of the programming languages battling for a place in programmers' minds. What really makes a language popular? What really makes a language 'good'? What is success for a programming language? Can we say COBOL is a successful language? What about Ruby, Python, etc?"
The "un-success" of a language (Score:3, Funny)
Fact.
Re:All Programming Languages Suck (Score:5, Funny)
Beards (Score:5, Funny)
Grace Hopper & John Backus didnt have (Score:4, Informative)
Re:Beards (Score:5, Informative)
Off the top of my head? (Score:4, Insightful)
Re:Off the top of my head? (Score:5, Interesting)
Re:Off the top of my head? (Score:5, Insightful)
Python also plays well with C [python.org], so it's often used in concert with C for interfaces, etc.
Re:Off the top of my head? (Score:5, Interesting)
Re:Off the top of my head? (Score:5, Insightful)
For instance, in my day to day life, I see a clear distinction as to when procedural/object oriented languages such as C, PHP, and Java should be used, and when a relational language like SQL should be used, and I rarely confuse those two classes of programming. Markup languages (though hardly programming languages) like HTML and CSS also have their essential and distinct roles. Were I forced to select only one, I'd probably quit programming!
Programming languages are just tools to get the job done. When was the last time you saw a carpenter with only a chisel?
Everybody's so quick to get into pissing matches.
(Forgive any flawed terminology, I was just speaking casually.)
Re:Off the top of my head? (Score:5, Funny)
When's the last time you saw a contractor with 7 power-drills all made by different manufacturers?
The answer is somewhere in between - one language isn't enough, but many languages are indeed superfluous.
Re:Off the top of my head? (Score:4, Insightful)
C is perfectly capable of many of the most useful object oriented techniques. Objects with methods and locals, classes (instantiating objects from models), inheritance -- all of these are easily and efficiently implemented in C without library or compiler-generated overhead. All the while, the programmer can remain in complete control, and the application can remain fast and lightweight. You can't do everything; there are some object-oriented paradigms that don't fit, but frankly, they're not critical. The important parts are easily managed.
Re:Off the top of my head? (Score:5, Interesting)
Re:Off the top of my head? (Score:5, Insightful)
Comment removed (Score:5, Insightful)
Re:Off the top of my head? (Score:4, Insightful)
Where the hell do you get C and bloat together? If anything written in C has bloat, the developer should be promoted away from coding immediatly.
Re:Off the top of my head? (Score:5, Insightful)
As for banging out quick projects, I tend to do them in C or shell scripts because I know they will either become real projects or they need to be understood by all.
Also doing things in a scripting language and having C do the heavy lifting... sounds like Tcl, Lua, JavaScript. Python offers nothing new there.
Re:Off the top of my head? (Score:4, Funny)
bloat vs big (Score:5, Insightful)
Not every big library is bloated. It's only bloat if it has a poor size to functionality ratio.
For example libc is small, but it does not include XML parsing, HTTP support, SHA1 and MD5 sums, the ability to read compressed files etc. Sure there are libraries for that, but you have to pick and add them yourself. So libc is small not because it is amazingly efficient, but because it is limited in scope.
Personally, I like big standard libraries like Java and Python have. You pay for it in the initial install, but once that is in place, your application has access to a huge amount of functionality without having to add a lot of external dependencies.
Re:Off the top of my head? (Score:5, Insightful)
I don't think that Ruby is bad, not by a long shot. It's seems fairly decent and it doesn't seem to be lacking anything necessary. I'm just curious as to why someone would pick Ruby over some other language. I'm not quite understanding what the "killer app" of Ruby is. I'm not sure why this language had to be created.
My understanding is that the main reason for choosing Ruby is to use it with Rails (which I have not looked at yet). And yet it's rare for me to read a good word about Ruby on Rails.
Does anyone else get the impression that a lot of these newer languages are simply solutions that are looking for problems?
Re:Off the top of my head? (Score:5, Interesting)
Furthermore, application complexity increases non-linearly with lines of code. The fewer the lines of code, the more maintainable and understandable the program.
This is one reason why C is a poor choice of application language, because it requires verbose solutions, and why OCaml is a better choice.
So the winning factor of Ruby over Java is its expressiveness. The big downside is the loss of static typing, and the subsequent loss of certain pre-runtime guarantees. If we could have both, we'd have a real killer language.
Re:Off the top of my head? (Score:5, Insightful)
There is much more to good programming languages than short code.
Re:Off the top of my head? (Score:4, Insightful)
Ruby is an order of magnitude lower in complexity compared to C++. Whereas Java continues to mix objects and immediate values (e.g., int and Integer types), Ruby has only objects. Java's mixed model has a cost when programming. You may reply that the immediate int gives you a speed and optimization advantage, and that is true, but it misses the point. Java gave up speed compared to C++ to make things easier on programmers, and Ruby simply continues in that vein. You can't criticize Ruby for continuing what Java accomplished to a much lesser degree.
There are numerous other examples - Ruby's iterators, for example, are a generation past what Java has to offer. You can find plenty to appreciate in Ruby vs. Java before you even start to talk about advanced language concepts like closures.
I hear only complacency in the above comment. You've learned a language well, and find it hard to imagine a better way. Well, your lack of imagination does not equal evidence.
Re:Off the top of my head? (Score:4, Informative)
decent and it doesn't seem to be lacking anything necessary. I'm just
curious as to why someone would pick Ruby over some other language. I'm
not quite understanding what the "killer app" of Ruby is. I'm not sure
why this language had to be created.''
Ruby was inspired by a number of good and useful programming languages, such as Lisp, Smalltalk, Perl, and Python. It combines the good features of those into a single language. The result is a language that is very powerful, has clean syntax, is easy to get started with, and allows a little code to do a lot of work.
As for a killer app, I don't think there really is one. Ruby is and has always been a general-purpose language. It got its 15 minutes of fame with Rails, but that has since been cloned in other languages. Nowadays, Ruby is just good at many of the same things Perl is good at, and good at many of the same things Python is good at. I personally prefer Ruby, because it is a very well thought out language and, coming from Lisp, it feels natural to me. Still, I don't think Ruby is that much better that people should or will be switching in droves. It's an incremental improvement over already good and useful languages, not a revolution.
Now, for some specifics.
From Perl, Ruby takes first-class regular expressions. Many Ruby modules are also ports of Perl modules.
From Python, Ruby takes clean syntax. There's quite a lot of competition between Ruby and Python, so I imagine there is a lot of "me too" on both sides.
From Smalltalk, Ruby takes the object system (everything is an object, every object belongs to a class), and blocks (kind of like anonymous functions, but with special syntax). Blocks, especially, are very powerful, as you can use them to (almost, I have to say as a Lisp programmer) implement your own control structures; loops, iterators, etc.
From Lisp, or maybe from other languages that have these features, Ruby takes garbage collection, anonymous functions, dynamic typing, call/cc, symbols as first-class values, printing of objects in Ruby-readable form, a read-eval-print loop (enter code, have it evaluated and the results printed) and probably a bunch of other features I am too tired to think of right now (but not macros, alas).
Ruby also has exceptions, the printf family of functions, and a number of other features commonly found in modern programming languages.
The kicker is that it has all this in a single, coherent language, with a syntax that is easy to understand and learn, and few great pitfalls. Mostly, whether you already know a programming language or not, you can just start coding in Ruby, and it will be easy. There aren't lots of irritating silly parentheses in Ruby, neither is there a difference between scalar and list context. No buffer overflows, no integer overflows, no memory leaks. You don't need to change the way you think, you don't need an IDE. It's easy to get started with, and yet doesn't suffer from problems that languages that are easy to get started with usually have: bad design, limited expressive power, only really being suitable to one domain, etc.
Finally, some code, just for kicks:
Re:Off the top of my head? (Score:5, Informative)
Personally, I think of Python as a prettier and more coherent version of Perl.
Re:Off the top of my head? (Score:5, Funny)
And this is why God invented comments.
Re:Off the top of my head? (Score:5, Funny)
Why, I believe you are one of those old style programmers who believe in making things simple, easy to read and maintain, straightforward to develop and simple to understand. How will you appear superior to your colleagues and peers if you write code that they can understand? You have no clue, sir, of the need nowadays to preen your feathers by appearing to "grok" something as obtuse and needlessly obscure as this kind of coding style.
If your code is so simple, and anyone can understand it, then there is no reason why it can't be shipped offshore to Elbonia. So, get with the program and spend at least an hour a day "refactoring" your code to the required level of spaghettiness. Thank you.
Re:Off the top of my head? (Score:4, Insightful)
Haskel suddenly very popular ? - the hordes of VB programmers got woken up to the world of threads
Elbonia - you're late, now Elbonians ship spaghetti code back to the less muddy countries
What makes programming languages popular ? - libraries
Re:Off the top of my head? (Score:4, Insightful)
Yaml does the same thing with whites space and the power of it is really evident when you compare it to JSON or XML. indeed you can put XML and JSON or HTML right into YAML without doing anything other than indenting it. No quoting, escapes, etc. so the other code looks "native" to the reader not encoded.
So I totally understand your fear of it. But it's just not justified and you are missing out on a big deal in language enforced, clean coding style that pays big dividends.
Re:Off the top of my head? (Score:5, Funny)
Re:Off the top of my head? (Score:5, Insightful)
I think the point is "which tool fits the current need best." Far too many people seem to want to use a hammer when a screwdriver would work better out of potentially misguided allegiances. Languages are no different than any other tool.
I suspect TFA is more 'overrated' than 'insightful' since it makes some gross generalizations, cites search results as indicators of popularity, and completely neglects some of the nicer features of the popular scripting languages.
Re:Off the top of my head? (Score:4, Insightful)
Re:Off the top of my head? (Score:5, Informative)
Re:Off the top of my head? (Score:5, Insightful)
If I can start a project in a particular language, get hit by a bus half way through, and finding someone else to sit in my seat and finish the project isn't a problem, then the language is a success. If I don't have that confidence, then the language is nothing but an interesting curiosity for academics.
Pretty cut and dried.
LOL perl (Score:5, Funny)
I don't really get the Java hate around here (Score:5, Insightful)
Java's well organized, has a great standard library and is (mostly) consistent with itself. Its only problems, as far as I can see, was that it was initially slow and that it marketed itself as a web language, when there were better choices for that.
Disclaimer: I've only coded in Java since 1.5.
Re: (Score:3, Insightful)
Before 1.5 it was harder to avoid those dreaded ClassCastException:s that you could get from Lists and Maps.
But it's still the NullPointerExceptions left to take care of.
Re:I don't really get the Java hate around here (Score:5, Insightful)
While Generics add a lot of protection by making your List strongly typed, using instanceof checks will protect your code when using a List.
Re:I don't really get the Java hate around here (Score:5, Insightful)
Re:I don't really get the Java hate around here (Score:5, Insightful)
I would also note that community can have a huge effect. Obviously the size of a community will have a strong effect on whether usage of the language remains, grows, or shrinks. After all, you are more likely to learn a language if you hear about it, if it's used in many other projects, etc.
Additionally, community is important in terms of the amount of support you get. Languages with strong communities will have thousands of online tutorials, excellent forums that provide responsive help, freely available code snippets, plenty of libraries and add-ons, and so on. This kind of 'free support' is often more useful than even careful and exact core documentation.
As a personal example, I (have to) use a programing environment called "Igor Pro [wikipedia.org]" at work. The language syntax bothers me a bit--but on the other hand it is specialized to do some of the things we need it to. But what I really hate about it is the lack of community. When I Google for an answer to a problem I'm having, I get nothing. When I try to find a pre-made package for a non-core feature, it doesn't exist.
Compare that to solving the same programming problem in, for example, Python. Even if it's not the optimal language, the fact that I get find tons of help online, and that there are so many community-developed packages and libraries, means that I can often solve the problem much faster.
When evaluating new languages (and new software products), I always take the time to find out what the community is like. It can make all the difference.
Re:I don't really get the Java hate around here (Score:5, Insightful)
They're not very good (or weren't for a long time), they feel cobbled together at best. But they work. They're fast, have a low learning curve, they're accessible and essentially cheap and/or free. They're easy to deploy and shove into production fresh off the prototype phase.
They have large numbers of people who use them as their primary tools. A large percentage of these people are not exactly what you'd call professional developers (I am not a developer, but I've worked closely with them throughout my career), yet they get "the thing" done somehow, and those systems tend to stay up there driving business for a long time.
It's just funny that the very phenomenon that for years and years the platform and language purists argued was one of the Really Bad things about Windows is actually now coming to Linux in a big way. What those elitists never realized is that most developers just want to get the business of business done, cash a paycheck and go home to their families. They don't care that there are 19 different ways of escaping a string in the runtime library. No one cares about that, as long as the platform continues to deliver, even if it just sort of limps around.
All those thousands and thousands of clueless VB/Access/VBA developers don't suddenly become little Donald Knuths because they're looking at a KDE desktop and using Emacs to code curly braces in PHP.
Java's not going to die (Score:5, Insightful)
The company sponsored a trip to JavaOne at San Francisco earlier this month, for the Dev Team. I also got to go. This was my first time at JavaOne. It was amazing, exciting, and I learnt a LOT of new stuff. The main thing I got from there was that Java, far from being a programming language, is also a platform. There are a lot of new things being built on TOP of Java. For example, Groovy [codehaus.org], and JavaFX [javafx.com]. Java now has excellent support and frameworks to roll your OWN domain-specific languages.
Python and Ruby are not going to push Java out of the way. For example, you have mergers of Java with these languages (Jython and JRuby). Essentially you have Python and Ruby using Java resources and libraries. I think instead of "dying", Java is just going to evolve into a stable platform that lets you build stuff on top of it.
Re: (Score:3, Informative)
My first experiences with java were the stuff that ran like crap as the so called end-all-be all write once run anywhere GUI language. That is not true today. Java is now a middleware language. Its become glue, and more behind the scenes than it was back in the day.
So, what makes a programming language successful? Well, of course, its success!
No, seriously, today, a program
Re:I don't really get the Java hate around here (Score:5, Interesting)
the author looks like he is inexperienced, and unaware of the function "reduce", which was added initially as a patch to python 1.5 by an experienced lisp programmer (along with map, lambda and filter) and so his example in section 10 could be replaced with:
from operator import add
reduce(add, [1,2,3])
but the point of mentioning this is that java is extremely verbose - and consequently cumbersome.
there is a class of programming language which python 2.x, lisp, smalltalk and other extreme-OO languages fall in to, which have an incredible elegance of expression and a level of empowerment that is wayyyy beyond anything else.
it is not possible to count python 3000 in amongst those languages with extraordinary power, because the developers - primarily guido - believe that the functional-language-based primitives (map, lambda, reduce, filter) are "unnecessary".
i initially thought that this was a joke - it was announced on april 1st.
unfortunately it turns out to be true. the removal of these key features is profound: the language (python 3000) is dead before it is completed. it's difficult to explain but these functional-language primitives are extraordinarily powerful, providing a kind of "zeroth dimension" of data manipulation.
on a single line, you can do incredible data manipulation. i regularly do things like this:
from string import strip
for l in open("file.csv").readlines():
l = l.strip() # take off newline especially
l = l.split(',') # split by comma
l = map(strip, l) # strip white space
l = map(int, l) # convert everything to ints
of course you could fit that all on one line but i deliberately kept it to 4 lines in order to include the comments. you could also equally do this:
l = l.strip().split(',')
l = map(lambda x: int(x.strip(), l)
the flexibility is just... amazing, in python.
the other thing about python is that it tends to be self-documenting, and also, there appears to be a tendency of coders to actually write _some_ documentation.
that, and the fact that it is possible to walk the source code (or, more usually, the object-code) and 'read' it from inside a program, such that you can access the documentation strings and in fact the entire program...
so things like happydoc can auto-generate you HTML documentation, by walking the code itself and collecting all the module, class and function documentation strings - just
i regularly do things like this:
import os
print os.path.__doc__
i don't bother to look up online how the function os.path works, i print its documentation string!
you just don't get these kinds of things with java.
Re:I don't really get the Java hate around here (Score:5, Funny)
the author looks like he is inexperienced, and unaware of the function "reduce",
Re:I don't really get the Java hate around here (Score:5, Informative)
If so, your criticism is bizarre, the example is written to illustrate that "Python Pre-2.1 did not have lexical scopes.", not to illustrate the shortest way to rewrite the built-in sum function (you realize that right, that the idiomatic implementation of sum in python is the built in function?).
The reason map and reduce aren't cared about is that most people have an easier time with list comprehensions. Your code:
l = l.strip().split(',')
l = map(lambda x: int(x.strip(), l)
can be written as:
l = [int(x.strip()) for x in l.strip().split(',')]
in python 2.4 onwards. Obviously, you could put that on as many lines as you wanted. If you are worried about performance, generator expressions are very similar to list expressions but lazily evaluated:
g = (int(x.strip()) for x in l)
g would then create items as they are called for by some consumer (for instance, a for loop or a container object).
Re:I don't really get the Java hate around here (Score:4, Informative)
1) Those capabilities will still exist in the base language, just with different syntax.
2) If you want the old syntax, it will be available in a standard library.
Save your hysteria for something genuinely catastrophic, like the loss of the print statement.
Re:I don't really get the Java hate around here (Score:5, Insightful)
Same with any interpreted language. PHP, Python, same problem if you are using deprecated accessors. Heck, even the MySQL connector worked differently in PHP3
Are you really suggesting that every time there's a new version they change the name of the language? What about changing the name of every program you write just because you altered the API? Why would you say it's unacceptable?
Re:I don't really get the Java hate around here (Score:4, Interesting)
I am talking about the client here. Having a minimum JRE version is fine, but did the Java developers remove features from the language and not leave and backwards-compatibility hooks in it? That's the only reason I can see why a Java software package would require a version LOWER than "current."
If you write a new version of a programming language you created, and old programs do not work AT ALL, then you have done something wrong. Adding features, improving efficiency, etc is fine (great). Removing functionality does not make sense.
Re:I don't really get the Java hate around here (Score:5, Informative)
Are you serious? Where I work, we regularly use at least three Java applications, and each one requires a particular version of Java, none of which are the same. One of them requires Java 1.5, while another one will break completely if Java 1.5 is installed. It's a nightmare! And while yes, the version requirements may be the fault of the developers, the fact that it can happen at all is unacceptable.
-Em
Re:I don't really get the Java hate around here (Score:5, Informative)
Re:I don't really get the Java hate around here (Score:4, Insightful)
And the point of software is the usage, not the creation. So dealing with issues during creation is the developer's problem. It needs to be usable by the client.
Re:I don't really get the Java hate around here (Score:4, Insightful)
Now that's nonsense if I've ever heard it. If that were true, Linux distros wouldn't need package managers.
Re: (Score:3, Insightful)
> With itself.
When I see "itself" I consider "Java 1.4.02_09" and "Java 1.4.02_12" to be within the realm of "itself". Yet these two versions (just as an example pair, my argument is not exclusive to just those exact versions) have compatibility problems. Or rather, the developer of the software we use has those problems. But the fact that upgrading by an extremely minor amount (I'd say a 0.0.0.03 version increase is extremely minor) can break an application
Re:I don't really get the Java hate around here (Score:5, Interesting)
The bottom line is that no language will ever make the programmer smart. If the programmer is dumb enough to use some esoteric/ undocumented/ unsupported part of the JVM (Sun has a number of those, but no, it is NOT easy to get stuck on a specific JVM rev unknowingly) - thats the programmer's fault. If the app is supported (or at least open sourced) fixing this sort of a dependency on a particular version should be quick and easy. If you do not have code and the app is not supported, then you really shouldn't be running it in the first place! Sounds like the app was abandoned long before you realized it.
-Em
Re:I don't really get the Java hate around here (Score:5, Insightful)
Actually, it suggests that he hasn't coded Java for very long.
Regardless, if you're building a web application, you're probably not going to build it in Bash. The right tool for the job, and all that.
It's silly to say "Language A is better than Language B". What makes more sense is "Language A is better than Language B at task X."
Java is the right tool for many jobs. It'll die shortly after C dies (in other words, not anytime soon).
Re:I don't really get the Java hate around here (Score:4, Insightful)
I don't have enough experience with the others on your list to vouch for them, but I often see Ruby on these lists and my experience with both doesn't bear it out.
grmbl. (Score:5, Funny)
those who don't know how to use it.
Back to Basic (Score:4, Interesting)
The lack of type-safe variables, the possibility to write unreadable code, hunt for bugs that are caused because two files are incompatible. Interpreting languages has been tried before, and they are never working for large projects that shall live for a long time and has to be maintained by a lot of different programmers.
Java may be a bastard of Ada, but at least it has some type checks built in. However, it's a bit weak on the side where the user can't control memory management in a good way. Another weakness is that methods can't be declared to allow/disallow the return of 'null' values to be detected at compile-time.
Re:Back to Basic (Score:5, Interesting)
Perl is what it is: A quick and dirty language for generating practical programs. It's ugly, it's hard to maintain, and it makes a lot of peoples lives a lot easier by making operations that are extremely complicated in other languages quite trivial to code. Comparing it to C is not an apples to apples comparison. Comparing it to BASIC is like comparing a Pineapple to a Raisin.
Re:Back to Basic (Score:5, Interesting)
Python assumes you know what the hell you're doing, so it won't throw errors if you create two variables, put an Int in each one, and do an Int operation on them, all without declaring a type...It'll figure out the type by context.
However, if you try to multiply an Int by a String, it'll throw the same type errors any other strongly type language will. They call it "duck typing [wikipedia.org]."
Re:Back to Basic (Score:5, Funny)
Re:Back to Basic (Score:5, Funny)
Faulty pronoun reference. Which one am I talking about? You'll never know. (And if you pick one, I'll just say it was the other one.)
Re:readability (Score:4, Informative)
BASIC and Pascal are procedural [wikipedia.org].
SQL is declarative [wikipedia.org].
That's not why they're that way [wikipedia.org] at all.
Python's a great language, but that's no reason to get sloppy about the details.
Easy. (Score:5, Insightful)
Performance: How fast can it do it?
Ease of Development: How fast can quality code be turned out by regular programmers?
Most modern languages fail on a couple of these. C is first class in Power and Performance, but it's not Easy. Ruby is okay in Power, and its very Easy, but it's slow. Java is Powerful, but doesn't match C for Performance, and it's not the quickest for development.
I'm sure many fanboys will disagree with my analysis. They'll say "Regular programmers don't matter (C)" or "It's NOT SLOW (Ruby)" or "Development is too quick! (Java)".
Really though, that's what it comes down to. The problem is, that there are unfortunate tradeoffs that have to be made. Most languages have a strength, but they all make sacrifices to be strong.
Aging Engineers (Score:5, Insightful)
Re:Aging Engineers (Score:5, Insightful)
The kids wanted to do OOP. My father felt there wasn't enough memory to do this effectively and it was foolish.
The reality was, that the kids just wanted to pretend they were doing OOP. They still used straight C, they just created structs and organized functions in files as if they were classes. It was actually rather clever and made it easier to maintain.
It's hard as you get older, I think, you hear about some new idea as the silver bullet and your immediate reaction is negative because you've heard this so many times before. But you have to have an open mind, and watch and see what is happening.
Otherwise you'll end up as a COBOL developer.
Re:Aging Engineers (Score:5, Informative)
Depends on your skills. C# is a safer environment, but C++ has immensely more expressive power. With modern and well-coded C++, these 1,000 lines may equal to 10-20,000 lines of C#/Java. Unfortunately, the ugly C++ syntax and its C cruft make unlocking the true advantages of C++ a black art.
A trivial example is the STL. Java/C# containers don't come even close to the STL's power. Go further and look at Boost.MPL/Fusion/Proto, and you'll see stuff you simply cannot do with Java/C#.
Well. If it were by me, Lisp would be king. But its not a perfect world
From whose point of view? (Score:5, Insightful)
If I was working for O'Reilly, Manning, APress, Wiley, et al I'd say a successful programming language was one which sold lots of books.
If I was a hiring manager for a large software company, I'd look closely at what language allowed the most cheap new grads to work together an produce something resembling quality code.
If I was teaching intro to computer science, I'd worry about what was preparing my students for the rest of their education.
If I was teaching a certificate-level course to people looking to get into the job market quickly, I'd look for the language with the highest placement rate.
If I was a person of little clue, I'd go largely by the hype. Some would go with the mainstream hype, and some go with the counter cultural "that's the big hype, but our language is better" underdog hype.
As a programmer, I prefer the language that helps me turn customer requirements into working programs that fastest with the least fuss on my part, and allows decent maintenance and customization later.
As the owner of a small boutique programming shop, I want my expressive, powerful language to give me an advantage over others using less expressive languages. I'd like to find others who can use it, but a few is alright as I don't need a huge team to work on programs.
Re:From whose point of view? (Score:5, Funny)
Re:From whose point of view? (Score:4, Funny)
Python's Success.. (Score:3, Funny)
Re: (Score:3, Funny)
Quck! (Score:4, Insightful)
Re:Quck! (Score:4, Funny)
SOME Answers: (Score:3, Interesting)
Having multiple abstractions available. Multiple ways to do the same complex task efficiently, not just for() or while(). Regex plz.
Being able to access hardware directly. This includes RAM allocation.
Few unexpected side effects. Documentation is important for both adoption and maintenance of programs written in the language.
That's all I got.
Ruby and Python are ex-parrots, not Java (Score:5, Interesting)
I've reviewed 400-500 applications (it's unclear to the total number, but I usually do a review every other week, some shorter, some longer).
I've never reviewed a Ruby application or been asked to review code written in that language. I have been asked to review a Haskell application.
I have reviewed:
* 85-90% Java, usually with shell and ant scripts and occasionally some Perl. Some *years*, this is the only language I am asked to review.
* 5-10%
* 5% COBOL. Primarily as a side line - there's a lot of old code to review, but most folks never do.
I've reviewed three PHP applications professionally, all in the last year, even though this is my preferred language to write stuff.
Java is overwhelmingly used in large commercial settings for high value applications, with
I don't get to review that many COBOL or other mainframe apps. I've been doing ground breaking research in this area as there's no advice today. There is a false belief that this code is somehow "safe" as it resides on the mainframe. Nothing could be more wrong.
Ruby and Python, although interesting langauges, has zero commercial penetration, even for worthless brochureware or community apps.
What they do have is an extremely loud fan base. These languages will not kill COBOL or Java any time in the next forty years or so as the fan base is fickle and will move on to the next big thing when it comes along.
Re:Ruby and Python are ex-parrots, not Java (Score:5, Insightful)
I think your field of work is too narrow to be completely explanatory.
Btw, I do agree with your general point - I don't see python or ruby bumping aside java. But your personal experience, extensive as it appears, is not enough to derive that conclusion
-Jeff
P.S. I really wish java would go. I hate the upper/lower case thing in all the names.
Re:Ruby and Python are ex-parrots, not Java (Score:5, Insightful)
Do you ever think that maybe your survey has a heavy self-selection bias? I mean it seems to me that the most likely candidates for security reviews would be applications that have been around long enough to have somebody in management say, "Hey, we need to have a third party review this!". This explains how FIVE PERCENT of your applications are COBOL while only "three" are PHP. By your analysis, it's as if C/C++ doesn't even exist...
Re:Ruby and Python are ex-parrots, not Java (Score:4, Insightful)
However, you have a point to a degree - I am initially more productive reviewing frameworks I am familiar with. But that doesn't mean I would be ineffective at reviewing Python or Ruby. It would take me about half a day to spin up in any language or framework as I found things that are missing. And that's the important thing:
I hate reviewing apps with zero security engineering. It's exactly like shooting fish in a barrel, but hopeless as you're not going to get a nice fish stew at the end.
What I look for are meta-issues found in all languages and frameworks. Syntax and functions can be found in online references - if you need them.
There is nothing special about any language as few protect against the security artifacts we look for.
For example, if your code has an access control mechanism, I look at it in situ on a live test app, deciding how best I might attack it, and then research using the code how I can obviate it at different levels:
* Coarse grained - is this feature access controlled at all? This is definitely a problem for J2EE apps that use servlets as folks think presentation level security is adequate. It's not
* Medium grained - does this feature offer different levels of access based upon your role? If so, how does this mechanism work? What do I do to get around it and steal stuff?
* Fine grained - does this feature restrict access to secured resources (direct object references)? If so, how does this mechanism work?
Each of the things we look at are verifying security mechanisms. Knowledge of the language or framework is simply not necessary. If you know what you're doing, you can prove the lack of security engineering by testing the app in situ and then research why it fails. Once I find a weakness, I look at the code to see why the weakness exists. Once I've found the issue, I look further afield for the pattern and then I document the issue. Rarely does an app or framework have just one weakness - they are usually patterns.
Picking up a new language or grammar and framework, like going from Struts to Spring MVC takes about half a day for someone like me who knows multiple languages, both functional like Haskell, or OO languages like Smalltalk or Ada, or scripting dynamic languages like PHP, Ruby or Python, or declarative languages like C or Java. We do not write the app, we are reviewing the app.
Security mechanisms are usually fairly clear if they exist. If they do not make themselves immediately obvious, they are usually missing.
Folks who have the hubris to think their code is somehow safe, like the COBOL folks on the mainframe or your example of not reviewing code if you don't know it well. That's why I turned down the Haskell review as I didn't know it well enough in the time available. If it was a longer review, I would have taken it as I love to learn new languages.
However, fyi, if you paid me to be a developer, I could be immediately productive in the following languages:
J2EE - Since Java was first released. Major frameworks include Struts, type 1 JSP with JSTL, Spring MVC, Struts 2.0, and JSF
PHP - Since PHP 3
Could code if absolutely required:
COBOL - 12 months review only experience
RPG - 12 months review only experience
Perl - 15 years experience
Shell scripts - 15 years experience
Ruby with RoR - tested it out for a new version of my forum (UltimaBB/XMB) but it was too slow
C - since 1985. Co-wrote the Matrox millennium driver for XFree86 back in the day
C++ - since CFront was a bastard child
Ada - since 1990. Still have fond memories
Pascal - since 1985, haven't used it for a while
Languages that I don't suck at but wouldn't claim any particular skills:
Re:Ruby and Python are ex-parrots, not Java (Score:4, Funny)
The "scripting" vs "compiled" canard again??? (Score:3, Interesting)
One thing ain't got nothing to do with the other.
I can't decide which is worse, this particular bit of idiocy or the all-to-common: "dynamic vs strong typing" arguments.
Actually, maybe I'm being to hasty.
The conflation of runtime implementation details with language capabilites, or the above-mentioned typing confusion, does provide a quick and easy way to tell that someone doesn't know what the hell they're talking about.
Perhaps a better measurement than /. popularity (Score:5, Interesting)
Rather than a "gee I need a cool website for my mom" choice, perhaps the number of transactions or dollar value would be a better count.
Cobol would probably win, followed by java and the Microsoft languages (C++, C#).
Re: (Score:3, Insightful)
1. They have highly experienced developers that are widely available.
2. Apps written in them are generally older and have been time-tested and are reliable.
3. The language and its behavior is well understood and is well honed.
4. Many libraries are available
Changing to the latest and greatest language demands that you have a damn good reason. Hopefully you just have to port an existing app but you'll have to start all over with QA
Re:Perhaps a better measurement than /. popularity (Score:5, Informative)
C++ is NOT a "Microsoft language".
Expert@work ... (Score:4, Funny)
Elsewhere [oreillynet.com]: "Python Creator Guido van Rossum now working at Google"
Well. Now I finally know how Google is dangerous.
CC.
What makes a programming language successful? (Score:4, Insightful)
Same thing that makes a religion successful. Adherents.
Its partly the API... (Score:4, Interesting)
Obviously there's more than one factor to a language's success, but the breadth and quality of the libraries and application frameworks is a huge factor - if you "know a bit" about programming then I'd say that learning your way around a new API is just as much work as learning a new language.
A big plus for C was that it always came with a substantial standard ("de-facto" to start with, then ISO) library based on the Unix API so it was great for writing portable programs - c.f. Pascal where ISTR the core language couldn't even open a named file. C++ was largely popularized by application frameworks like MFC and OWL, and Delphi did the same for Pascal.
PHP is pretty fugly as a language but comes with a huge library of functions and add-ons that are just what the doctor ordered for web scripting - and when people talk about Ruby, do they really mean Ruby or do they mean Rails?
I don't know about Python - it seems to be a secret society rather than a language and you can't join unless you pass this initiation test where someone tells you a corny joke (stolen from an ancient email circular about Unix and Makefiles) about a language which uses leading whitespace to delineate blocks. I always laugh and fail the test, so I've no idea what the real language is like. :-)
Irony (Score:5, Interesting)
For example, I worked on one project which was a client/server system which handled maybe 10 transactions per second, with each transaction translating into maybe one or two table updates. The application could have been put together using something simple, like Tomcat and MySQL on the back-end, and something easy to use like an XML/RPC link to the client side. (There were only something like 10 remote procedure calls being made, and this was an internal application, which means the total audience was perhaps 100 people.)
But rather than keep the whole thing simple, we had a whole bunch of "Architecture Astronaut" wannabes who started tossing in third party frameworks like there was no yesterday, without carefully thinking if the framework was needed, and if so, how best to integrate the framework. Before we knew it, the server was broken into 8 separate EJBs, Hibernate and Spring were called in to handle the server side coding framework, and the entire build process was so complicated it no longer could be run or debugged within an IDE--apparently someone on the project didn't understand ant and used makefiles for part of the build. And to top it off, because so many different frameworks were thrown in for no good reason I can determine (there were something like 40 third-party jar files in the build directory), there were all sorts of runtime problems as each jar file was not designed or tested on the full range of Java 1.4 - 6.0 environments.
Now if this was my first exposure to Java, I'd say that while the core language itself wasn't bad, the entire Java ecosystem sucked hard core. But no; it was the developers: rather than keep it simple, they used the 'refactor' button in NetBeans about 100 times too many, until what should have been a one person-three month job turned into half a million lines of crap, that, to their credit, limped along okay.
Knuth said that the most important thing is... (Score:5, Funny)
FFS (Score:4, Insightful)
Anyone can play Devil's Advocate and make one language look better than another from some point of view, but the fact is, different languages have their different pluses and minuses. I'm sure Ruby and Python have their pluses, but I don't see them being used NEARLY as much as Java. And take into consideration that Ruby has been around just as long as Java and Python has 4 years on both languages. If they were going to kick Java's ass, it would have happened by now.
I suspect the article is wishful thinking (though I can't read it 'cause the site didn't survive this post). I don't know why people have to make such a big deal about this stuff anyway. Languages evolve and new languages and paradigms will be created in the future. Computer programming is still in its infancy. There's a good possibility that 20-30 years down the road, none of these languages will be around. They may be completely replaced by some far more powerful paradigm we can't even imagine yet.
These kinds of predictions are old and pointless.
Another related case (Score:5, Interesting)
Consider a much earlier example of a math-like language: APL. It allowed concise programs and elegant expression (especially of mathematical ideas, like matrices); it ran in the then-mainstream environment (IBM mainframes); and, it was sponsored by the industry's 800-pound gorilla. And it was the best language for creating write-only programs that I have ever encountered -- think Perl with an extra helping of math and a non-standard character set thrown in. The worst programming assignment I ever had (although I did complete it successfully) was debugging and fixing a financial modeling package written in APL. My take on it was that the programmers who had written it originally fell mainly into two categories:
Smalltak is a huge success and also a failure (Score:5, Interesting)
If I had to pick a language to discuss and deem successful, it would be either Smalltalk or Lisp. Some people find either of those esoteric or "weird," but I rather enjoy writing code in both. Interestingly enough, in many respects neither language is particular successful in a commercial sense, but very much so for most implementations.
I'll stick to Smalltalk because it's a good example for this discussion. It's a case where popularity in my mind is not equal to success. Smalltalk works because it is simple (there are really only 6 keywords or so and not even really keywords at that) and is designed impeccably. If success is related to imitation and admiration, then Smalltalk is up there. Of course in itself, the language is derivative, but it's well-known enough to claim/steal credit for one of the best implementations of existing ideas. I have to laugh at other languages, especially Ruby, Python, C#, and Java as they are adding language features or libraries that emulate things that have existed in Smalltalk for 20+ years. That's rather laughable, but also an indicator of success.
As the Smalltalk saying goes, "Files? How quaint." The language just proves you can design something successful by simplifying and focusing on enabling people to design and use their brains. I feel like I can focus on code rather than language constraints. Smalltalk coding is like teaching them to farm rather than giving them food. There are obvious merits to both approaches. The fact that the language is still around 20+ years later and gaining momentum speaks volumes.
I think what makes it unsuccessful is that a lot of people have no idea it exists in the first place and how it really works. They might look at it and say, "yeah that looks something like Ruby, so what's the point." Usually I find it's lack of understanding of not only Smalltalk, but the fact that the development environment in many ways is the language. Most Smalltalk implementations simply don't have the problems in file-based languages like disorganized code, "too many classes," etc. So many of the plights in other languages don't happen in Smalltalk because of the design and that to me is success, regardless of the number of commercial installations.
Another issues that has halted the language's success in commercial spaces has been ugly UI. Until recently, most implementations have looked awful. Squeak used to look like a child's toy without customizations (still does to some degree, but there's 100s of customized images floating around the internet now). Visual Works looks like an ugly ms-app sometimes, but is a huge leap over the past. Gemstone Smalltalk has no real UI (but can use Squeak). The list goes on, but the point is that even in dev environments, eye candy has a big influence.
It gets even weirder when you look at Smalltalk and languages from the perspective of supporting products. Databases are probably the biggest, and Smalltalk can work with just about everything, but the simple support for the RDBMS is pitiful compared to most popular languages. Especially in recent years, a lot of that has to do with the Smalltalk view. In the Smalltalk world, it seems stupid not to use an object database at this poin
There is Only 1 Rule: My Time is Important (Score:5, Insightful)
I don't give a crap if language xxxxxxx is more efficient, more hardcore, etc. You know why?
Because I don't want to spend a year writing an application in C for efficiency and find out at the end that for a mere $1,000 I could have written the same thing in Python in a month and just bought a faster computer 11 months later.
YOUR time is linear, while the computer's is exponential. You'd be a fool to not take advantage of that and, frankly, type safety, efficiency, platform independence, programming style, power, etc. etc. can all go to hell. Just give me a beautiful language.
a GOTO statement (Score:5, Funny)
COBOL a success? Why is this even a question? (Score:5, Insightful)
Is COBOL old? Certainly.
Is COBOL outdated? Yes.
Has COBOL since been replaced by better languages? Yep.
Would you be insane to start a new, large, application from scratch using COBOL? Of course.
But "Is COBOL a success?" Without doubt, yes. Countless millions (perhaps) billions of lines of production COBOL code are still in use. It is still the core behind many of the applications that run our day-to-day lives. These applications have been running for decades with downtime records that would put an average "Web 2.0" app to shame.
Certainly, IBM deserves a lot of credit for this, maintaining pure 100% backward compatibility for those apps for the last forty years or so, but some credit is due to the language itself.
SirWired
Re: (Score:3, Insightful)
TFA:
Re: (Score:3, Interesting)
Have you seen the new 3.0 libraries?? MS Application blocks look a lot like J2EE when it first came out + the best of Jakarta that we have all been using for almost a decade. Don't get me wrong C# does a lot of "good" stuff... but a lot of its most "innovative" stuff is just finally bringing it up to snuff with the way we have all been using J2EE since the dot com bust.
Re:Yes, sure, it is the evil gang... (Score:5, Insightful)
while (x-->0) { blah; }
are so cool and easy to understand. and malloc()s make memory management so easy and cross-platform. and clustering is for wussies, if you need more than a core2duo on Linux, is because you're unl33t or because you need to do some routines in über-ELITE assembler.
now when you program in Java you forget all that crap, you just code. need a bigger app? J2EE it and run it on a cluster. add nodes a needed to keep performance. node dies? no problem, J2EE takes care of it.
migrated from mysql to Oracle or DB2? no problem, just let Hibernate know about it.
tired of Windows Server and want to run opensolaris, linux or OS X Server? no problem, just drop your EAR/WAR on the new server and relax. it's working.
wanna add more coders to your project? point 'em to the javadoc and let they read through the verbose (and thus self-explaining) code.
strong typing is there to keep you from doing stupid things. you can always tell what the program IS going to do in all situations, because you HAVE to specify all situations.
but you're too cool for java. lemme know when banks switch their systems to LAMP and we'll talk.
Re:Languages and technology stacks (Score:4, Insightful)
> Honestly, C is full of design errors.
Come back when you know how the computer works, grasshopper. C doesn't treat arrays as "objects" because the computer doesn't do that. If you want higher level abstractions, use C++, where you have the nice vector class that does what you want.