Information related to computer programming

Yoda Conditions alvin May 5, 2019 - 9:15pm

I had never heard of the term “Yoda Conditions” until now, but I have seen them in some Java code where programmers put the constant first in an effort to avoid null pointer exceptions.

How to use `curl` scripts to test RESTful web services alvin May 1, 2019 - 7:08am

There may be better ways to do this, but when I was writing a mobile app, with the JavaScript client written in Sencha Touch and the server written with the Play Framework, I wrote some curl scripts to simulate GET, POST, DELETE, and PUT request (method) calls to my Play Framework REST/RESTful web services.

Joe Armstrong: Why OO Sucks

Famed programmer Joe Armstrong passed away this weekend. He created the Erlang programming language, based on the actor model, and without using Google, I’m pretty darned sure that Erlang had an impact on Akka, the very cool actor library for Scala. Here’s an article Mr. Armstrong wrote some years ago, titled, Why OO Sucks (OO as in OOP).

The meaning of the word “reify” in programming alvin April 7, 2019 - 12:25pm

I don’t recall hearing of the words “reify” or “reification” in my OOP years, but that may be because I studied aerospace engineering in college, not computer science. Since learning FP I often see those words, so I thought I’d try to understand their meaning.

The short answer is that the main definition seems to be:

“Taking an abstract concept and making it concrete.”

For the longer answer, I found the following definitions and examples of reification.

Write shy code — modules that don’t reveal anything unnecessary alvin April 3, 2019 - 10:47am

“Write shy code — modules that don’t reveal anything unnecessary to other modules and that don’t rely on other modules’ implementations.”

~ Dave Thomas

SQL joins as Venn diagrams alvin March 20, 2019 - 1:06am

I saw this “SQL joins as Venn diagrams” image on this Twitter page. To give attribution to the original author, it appears to have been created by C.L. Moffatt and documented in this Visual Representation of SQL Joins article. However, this article makes the case that Venn diagrams are not an accurate description of SQL joins.

Roy Carlson: The sooner you start to code, the longer the program will take alvin March 18, 2019 - 12:02pm

“The sooner you start to code, the longer the program will take.”

~ Roy Carlson (which I saw in this tweet)

In general, I’m a fan of that quote, meaning that the harder the problem is, the more I like to find a whiteboard or some index cards to work through the problem that way before I start coding.

Testing takes time, just like structural analysis takes time alvin March 2, 2019 - 11:25am

“Testing takes time, just like structural analysis takes time. Both activities ensure the quality of the end product. It’s time for software developers to take up the mantle of responsibility for what they produce. Testing alone isn’t sufficient, but it is necessary.”

~ Neal Ford (as seen on this tweet)

Jupyter Notebook project alvin February 21, 2019 - 5:47pm

At a Meetup in Boulder, Colorado last night I learned about the Jupyter Notebook project.

Best practices for software development (continuous integration) alvin February 10, 2019 - 6:28pm

This Wikipedia page on continuous integration is actually a good resource for computer programming best practices.