DEV Community

Cover image for The Art of Programming

The Art of Programming

Erika Heidi on May 02, 2019

One of the most consolidated misconceptions about programming, since the early days, is the idea that such activity is purely technical, completely...
Collapse
 
alphydan profile image
Alvaro F Boirac

purely technical, completely exact in nature, like Math and Physics.

As a physicist, I can tell you that professional Math and Physics is mostly creativity, exploration, communication ... with some technical exact tasks added on. "School" physics and math on the other hand can feel hollow if the teacher doesn't reveal the creative side.

Collapse
 
erikaheidi profile image
Erika Heidi

Yes, I can understand that; but my viewpoint is from what we have to go through if we want to have a diploma in computer science & related, which is the route a lot of people will take in order to have a job in this industry. I am a college drop-out, so I am talking about my own experience that made me really disappointed with the field until I realized my path to programming was different and that was fine, too.

Collapse
 
chicobaptista profile image
Francisco Llamosas Baptista • Edited

I agree with your main point, programming is definitely a human creation process, that involves both creativity and logic.

However, I'd argue that so are Art, Science and Engineering. Scientists aren't cold logical automatons, they're some of the most creative beings I've had the pleasure to meet. The same goes to artists, who aren't also chaotic-driven vortexes of pure creation. Some of the best artists I personally know are surprisingly logical and methodical in their process.

In all these fields, there are, of course, those who tend to both extremes, those who look like they're automata, doomed to forever repeat the same taks without ever finishig the job, while there are others, who are so taken by the novelty and inspiration that abandon their creations before they're fully formed.
edited-venn-diagram

PS: Just a nitpick, I believe the Venn diagram should be more like this?

I'm not much of a hand with image editing, or I'd fixed it myself.

Collapse
 
erikaheidi profile image
Erika Heidi

You have valid points, however, the main idea of this post was to expose that we don't need to follow the academic path to be good software engineers, and it's more likely that someone without an academic background will bring more creative contributions to the field, because they're not "following all the rules". I am a college drop-out, and I'm talking about my own experience, which actually resonates well with many developers I know.

The venn diagram doesn't need fixing

Collapse
 
bcronce profile image
Benjamin Cronce

You'd be amazed what one can do without knowledge or experience. Most people think of problem solving as solving concrete problems. There is an infinite world of abstract problems which can map to real world problems.

You can practice on hypothetical problems purely in your mind, any time, anywhere. Before I had access to computer, books, or any form of knowledge, all I could do is think about how programming computers might work. After many years of obsession, I finally got to work on computers, and it was intuitively easy. Worked almost exactly as I figured it would.

This is beauty of logic. You don't need knowledge about the real world if your core set of axioms are solid. Programming is a subset of logic. Get good at logic and programming is easy.

Collapse
 
elmuerte profile image
Michiel Hendriks

"Computer programming is an art ..." -- Donald Knuth

“You might not think that programmers are artists, but programming is an extremely creative profession. Its logic-based creativity.” -- John Romero

Logic, art, with a dash of magic :)

Collapse
 
thecodingstoic profile image
theCodingStoic

I have to respectfully disagree. It isn't the Art of Programming but the Craft of Programming.

Merriam-Webster defines Craft as "an activity that involves making something in a skillful way by using your hands; a job or activity that requires a special skill; objects made by skillful use of the hands." While this definition focuses more on physical objects the definition is still applicable to programming. After all, writing good code is a special skill--technically done with the hands--to make useful and user friendly programs.

Furthermore, the Ethos of the Craftsman, as described by Brett and Kate McKay, can be applied to programming which I summarize and defend below.

  1. Do things Well for the Sake of Doing Them Well -- I am sure that we have all seen--and likely written-- cringe worthy code but I am also sure that we prefer to read and write well crafted and well documented code. Some of this comes down to competence in our craft but a large part of it comes down to us wanting to do a good job.

  2. Plan(But Not Too Much) -- I have my doubts that any of us have had any program, with the possible exception of Hello World, go exactly as we planned that it would but I am also sure that we all have a general idea of what the program will be prior to putting finger to keyboard. Allowing us programmers the same flexibility as those in traditional crafts.

  3. Measure Twice, Cut Once -- This one may seem to be the least applicable given the mutable nature of our craft. However, when working on a big project there are certain choices that can be changed but at significant cost. As such, the wisdom represented by this maxim--carefully consider the choices that you make before committing to them--are applicable.

  4. Work With What You Got -- while we may not have to worry about imperfections in stone or knots in wood we do have bugs in our code. Instead of scraping an entire project because of a bug don't we sit there, sometimes for hours, figuring out what the bug is and how to fix it?

  5. Cultivate Patience -- I think this one is applicable despite the seemingly fast pace of our craft because we may be working on a project for a long time or we need to have the patience to read source code or debug a program.

  6. Let Go of Your Ego -- Code Reviews. Enough said.

  7. Develop Your Practical Wisdom -- as our competence grows we can more intuitively know which approaches will work when solving certain problems; we can intuit issues that using certain approaches will bring and how to avoid them; we can read code and "see" the results.

  8. Mastery Brings Meaning -- mastery of our craft brings more satisfaction and meaning than what the particular craft is. Furthermore, no matter what the craft is that we practice there is no perfect craftsman. As such, there are always new things to learn and master.

  9. Find Your Workshop -- not only do we have our preferred development environments and our own "toolboxes" we also have the same, or similar, social aspects of our craft that guilds represented in yesteryear's.

So, I think I have laid out a good case for programming as a craft. However, I would like to say that just because I think programming should be considered a craft rather than art doesn't mean that we can't create beautiful programs that function as "art built on top of logic".

I want to thank everyone that read this comment and which everyone a good day.

Collapse
 
misnina profile image
Nina

"As with painters, there are many programmers who only replicate things, never coming up with something original.

Genuine artists are different."

I wouldn't call people who only replicate not genuine artists! Replicating good code practices or doing painting master studies is very important to technical knowledge, and being able to deconstruct something and put it back together the same way you found it is a pretty good skill that does take some creativity and curiosity. I get what you're saying over all though!

Collapse
 
bcronce profile image
Benjamin Cronce

You can't create good code just by following good practices. Code can never be better than its design.

Collapse
 
halbano profile image
halbano

I loved the quote and I immediately realize that same thing happen also with music and other kinds of arts. Art is built over kind of a logic layer, which are the (minor) things we already know from science (or something like that).

Thinking about programming as a creative thing -as an art- is the way to feel connected or fulfilled when you feel a bit disconnected seated behind a 'cold' computer. Also having in mind the sharing value and a continuous improvement mindset would make you fill aligned with a major purpose.

Collapse
 
rvictorino profile image
Robin Victorino

It's art built on top of logic.

create things "out of nothing", bringing ideas to life, with code.

Those words are very relevant (to me at least) !

It's awesome to see someone sharing the perception I have of the field. Thank you for putting words on it!

Collapse
 
codebeastmode profile image
Chris Quinn

Especially when it comes to formatting and organizing the code that you write. I can't stand when I open another developers file and it's just all over the place. It really irks me. Take pride in your work, because someone else is going to see it, do you want them to be happy/impressed by how well you have formatted/documented/organized your code, or do you want them to be upset that you just didn't give a $hit - we have to all stick together and realize that one day someone is going to have to modify our work, no matter how miniscule it may feel at the time, it may be that one function that you didn't comment that takes a beginner programmer all day to figure out because you didn't comment your code, and that programmer may give up all together, but if you would have commented your code, he would have changed the world! You never know.

Collapse
 
ambuj_twitt profile image
Kumar Ambuj

Cannot agree with you more.

Collapse
 
ben profile image
Ben Halpern

Yeah, I love it!

Collapse
 
jascha030 profile image
Jascha van Aalst

This resonates pretty deeply with me.
I dropped out of a graphic design school that provided an environment that truly felt like home to me (Grafisch Lyceum Utrecht).

I traded in their supposedly 'hardest study to get accepted' for a less then mediocre-IT study which felt like it was actively trying to be so uninspiring that teachers could get away with not teaching at all, because the few students left after year 1 are the "I chose IT because I just want to game in class" ones.
I officially spent 48% of the study, trying to numb the sense of constant disappointment through smoking unnecessary amounts of weed.

I switched because the graphic one triggered a perfectionist in me that was so impatient and strict that It resulted in me trying to ignore away the need for education (once again with weed).
So I made the sketchy (and uninformed) decision without any pre-existing background, in the naive hope for a very slim chance that "the actual work experience wouldn't suck".

I did this because I briefly talked to someone who made exactly this case which in my mind was a complete gamble but on paper seemed like it made sense...

This has been the best decision I made in my life so far.

Collapse
 
patternchaser profile image
Pattern-chaser - #SaveOurNHS #StopFundingHate

"The most creative people are EAGER to work in the shadow of uncertainty."

There, I fixed it. ;) Nice article! I have been saying this for years, but not as eloquently.

Collapse
 
zamanipour profile image
zamanipour

I could not share my feeling about ptogramming with my family and friends. I just knew that it is fantastic! Let me choose the way to create almost same thing with my better code, again better, better and ... This is me, this is my art! You describe it the way i could not.

Collapse
 
flrnd profile image
Florian Rand

This! I come from a Creative path (lately I was doing some art direction, branding and packaging). Some people don't understand that my work is still pretty similar than before. Now instead of Illustrator I use Nvim. But I continue creating solutions. The Core principles of what I did before to start learning programming continue the same.

Wonderful article!

Collapse
 
any97cris profile image
Cris Souza

I thought I was the only one who thought programming was an art. Your description is incredible. Realistic about the life of a creative programmer who, out of pure gift, creates systems with lines of code.

Collapse
 
vladimir_dev profile image
vladimir.dev

True... I'd say creativity is probably most important for problem solving

Collapse
 
ambuj_twitt profile image
Kumar Ambuj

Thanks for sharing @erikaheidi

Collapse
 
mdhesari profile image
Mohammad Fazel • Edited

Everyone can learn programming but you need to be so passionate and intrested in programming to become successful, if you do not have curiosity and it's boring for you to stay long hours in front of a laptop so you need to change your career...

Collapse
 
flosalihovic profile image
Florian Salihovic

There are not many artists out there ... while I agree on many aspects of your writing, that is something I would love to challenge. Most code written out there is written to just work. But by your definition everything is art. That takes away a lot from the real beautiful code written which is expressive, concise, runtime efficient and still understandable.
How much time did an artist spend sharpening his/her skills before he would himself call himself an artist - when would you call someone a genuine artist?

Collapse
 
luisfurquim profile image
Luis Otávio de Colla Furquim

if self === "Because they want to create, they want to express themselves in code" {
post("OMG! That's me!")
}

Collapse
 
silvestricodes profile image
Jonathan Silvestri

This contextualizes so well what it is I enjoy about programming. Thank you for a lovely article, Erika!

Collapse
 
mnavarrocarter profile image
Matias Navarro Carter

This is gold! Thanks for writing this piece. It really spoke to me. :)

Collapse
 
asafd1 profile image
asafd1

I agree. Writing code is a form of art. You create things that were not there.

Collapse
 
mi0epro profile image
Mihael

The beauty of art and programming combined.

Collapse
 
mjyc profile image
Mike Chung

Great article! I clicked because I thought it was about Donald Knuth's book, "the art of computer programming", but still was an interesting read. I especially found the diagram relevant & insightful.

Collapse
 
xowap profile image
Rémy 🤖

From the beginning I was expecting something more on the creative process 🤔

Collapse
 
pavelloz profile image
Paweł Kowalski

I think someone we owe a lot (Donald Knuth) wrote pretty good piece on the subject in 1974 - paulgraham.com/knuth.html - i highly recommend it.

Collapse
 
okabrionz profile image
Oka bRionZ

I Love You Erika!

Collapse
 
alexjuca profile image
Alexandre Antonio Juca

This inspired me to start thinking out of the box and look for wildly different ways to solve problems. Great article by the way.