Tag Archives: professional

The Three Modes of Programmers at Work

Over the years I have been able to observe how software developers do their jobs in a variety of circumstances, and I have come to the conclusion that developers operate in three distinct modes. These modes I call from principles, from cookbook, and trial and error. An individual developer often has a preferred mode, but will switch between modes depending on the complexity of the software being created, the developer’s own depth of skill, and the perceived pressure of the delivery deadline.

In sequence from most to least desirable, here are the three modes:

Small hall of learning with Greek architectureFrom Principles. This is how you were taught at school to do things. You learned the fundamentals of the programming languages and tools, and you learned good processes for turning a design into a software product. Later you sharpened those skills with practical experience. Programming from principles is what we have come to associate with beingĀ professional.

A skilled carpenter learns the characteristics of all different kinds of wood, and therefore is able to select the right wood for any project, whether it is a dining-room table or a doghouse. Similarly, a skilled developer knows different design approaches, and understands the capabilities and limitation of various software languages and libraries, and can so choose those that are best suited to a project at hand. During construction, the skilled carpenter uses his knowledge to make decisions along the way that may not seem obvious but which affect the quality and durability of the finished product. For example, what is the best way to join two pieces of wood? Choices range from a simple butt joint to a traditional mortise and tenon, to a sturdy-looking dovetail, to simply nailing. The decision is influenced by the type of wood, how much stress will be on the joint, whether the joint will be visible, and on how much effort he is willing to commit. Similarly, during the course of building a piece of software, the developer must make many small but non-trivial decisions that together determine the quality of the delivered product. The developer uses her professional insights to guide those decisions.

Raymond Chen, a software design engineer at Microsoft, writes an extensive blog in which he often relates problems submitted by clients. Many of these problems seem to stem from incorrect decisions made because of gaps in the knowledge of programming principles. For example, using a global solution to a local problem is a common misstep. If you want to prevent users from printing the contents of a particular window, the thing to do is find a way to flag only that window as unprintable, not disable the PrtSc key which affects all windows. In another recent entry, he shows how an understanding of fundamentals helps you make serious headway in analyzing a program failure. There, understanding the underlying memory model of the system helped Raymond make sense of the application data he saw, and informed his choices of next steps, despite being unfamiliar with the specific application.

Applications that we think are awesome usually come from programmers who have that deep understanding of the software platform, the application domain, and the professional practices. In other awesome apps are made by programming from principles.

Of course, in the real world, programmers often don’t have the timeĀ  — or inclination — to get a deep understanding of all the software platforms that they have to work with. Continue reading