Showing posts from November, 2019

Programmer Humor for the Holidays

Maybe we programmers take ourselves too seriously.  How else do you explain the infamous Google Manifesto written by James Damore linking programming ability to gender?  Or  Levandowski being charged with stealing Waymo's intellectual property and fleeing to Uber?  Or the growth of the tech-bro culture?

If only a sense of humor could be tested as part of the interview process!  I've found humorists and comedians to be remarkably intelligent, as a good sense of humor requires imagination, a strong grasp of wordplay, and the ability to read a room.

To help with the upcoming holiday gatherings, I've collected a handful of programmer jokes.  Use at your own risk.

Q: How do you get rich with C++?
A: Inheritance!

Q: Why is C a rude language?
A: Because it has no class.

Q: Why do Java programmers wear glasses?
A: Because they can't "see sharp."  (C#, developed by Microsoft, gets grudging respect as Java done right)

The one-liner below is credited to Eric S. Raymon…

Post Processing: Watch Your Language, Jaron Lanier Fixes The Internet

Watch the rise and fall of your favorite programming languages, set to music: Popular Programming Languages 1965-2019.   The lead changed multiple times and the YouTube video ended with the top 3 languages being Python, Java, and Javascript.  Okay, C# came in 3rd if you don't consider Javascript a real programming language.

This was the work of a first year PhD student who mined data from GitHub repositories and historic national surveys.  It's not far from the TIOBE index I wrote about in a previous Post Processing which ranked the top 3 languages as Java, C, and Python.

There is yet another language survey done by Stack Overflow.  It polled its membership, and nearly 90,000 developers responded.  While 90,000 is a healthy sample size, keep in mind those polled still represent a closed environment.

Top 3 loved languages: Rust, Python, TypeScript.
Top 3 dreaded languages: VBA, Objective-C, Assembly
Top 3 languages programmers want to learn: Python, Javascript, Go

These result…

Bookshelf Classic: Beautiful Code

This book is what you get when you ask 38 top software developers "What is beautiful code?"  An open ended question, you get diverging answers such as a deep dive into a regular expression matcher from Brian Kernighan, an optimization of population counts from Henry S. Warren Jr. (for bit-heads, not sociologists), and a treatise on why code is better treated as an essay from Yukihiro "Matz" Matsumoto.

For this post though, I want to focus on Jon Bentley's contribution, curiously titled "The Most Beautiful Code I Never Wrote."  Elaborating, Bentley writes

In software, the most beautiful code, the most beautiful functions, and the most beautiful programs are sometimes, not there at all.

He then uses the Quicksort algorithm to illustrate his point, first reviewing the code, instrumenting it with counters, and optimizing it along the way.  But the pressing question he tries to answer is: "How many comparisons does Quicksort make, on average, for a ra…