Are All Programming Languages The Same?: Python wins with Perl and Ruby close on its heels.
Fair enough. Des Traynor wondered if this table was valid, so he performed a simple test: he provides examples of a tiny “read a file and print it to the console” app in Java, Perl, Python, and Ruby. I’ll reprint the smallest version here, which happens to be the Python implementation […]
Java was the big loser at almost 4x the lines of the Python version. However, see the comments for some complaints about whether or not to count bracket-only lines — a problem from which Python does not suffer. Ruby either, for that matter.