Uncomfortable Truth About Programming

I woke a whole night and wrote the code on paper. Yes on paper. Can you imagine that? Now we have compiler within a web browser.

But it was back in 2004. I was learning c++. That was the first language that I learned.

In the first few classes, I was feeling awesome. All those beginner things like variables, statements and the most comforting printf function that makes your program speak 🙂

Until I hit by the concept of loops and nested loops. They knocked me down on the ground and I end up practicing the concepts on paper the whole night.

But I can tell you now that it was worth the effort. Whenever you are learning any new language or framework you will be learning quickly in the start.

If you have learned to code HTML or python. The beginning is always easy and you are accomplishing something new every day. When you see yourself progressing you feel good and when you stuck– you know it sucks.

But advance concepts require more time to digest. The following picture represents the typical learning curve for any programming language or framework.

Programming Learning Curve

The flat curve represents when you are learning advanced concepts of programming. Here learning a programming language becomes painful. Really painful.

The Pain is Important to Learning

If you are a junior developer you know that in the start you will fly through the basics stuff and easy problems but when faced with difficult problems your learning curve will become flat.

For junior developers, this pain is amplified when there is no one to help them out. They feel alone and even the developers at stack overflow scold them for asking questions(which seniors consider as naive questions).

Most of the people fell off at this painful moment. But in my opinion, this is the golden moment. The moment when you start to feel the pain while learning. Because pain represents long-lasting learning.

This is the pain that I felt when learning advanced concepts in C++. There were many hurdles. Help from my classmates was not possible and the computer at my home was malfunctioning.

The only working method was to practice even when I don’t have a computer, therefore, I practice on a piece of paper and later verify my programs on a computer.

My persistence besides the pain is still paying me. After that, I have never fallen during my life whenever I encounter loops or nested loops.

Pain Gives You a New Perspective

Another painful moment for me, when I was programming a real-world application in Visual Basic 6.  I still remember that I snatched my hairs out whenever I have to make changes to my code.

Is it because of VB6? It was because of bad code structure. Procedural programming leads to bad code structure. VB6 is a procedural programming language.

But I have seen people using JAVA/C# like a procedural programming language. Even I myself have fallen to this trap. Because every OO programming language allows you to write code in OO way but does not force you to.

The pain of bad code structure pushes me to create good code structure which led me to learn OO programming. If I didn’t snatch my hairs out then I will still be using C# as a procedural programming language.

I did not learn OOP for the sake of learning another programming language. I learned it because I wanted to write a good code structure. Now I create code structures where changes are easier to implement.

So, in my opinion:

If you don’t feel the pain of bad code you will not strive for the quality code.

Why Nobody is Telling you the Truth?

There is only one reason ‘Feeling of accomplishment’. Do you know why many books and khan academy coding tutorials start with ‘hello world’ stuff? Because the ‘hello world’ is easy and it will give you a feeling of accomplishment.

If they tell you the truth and throw the hard stuff at you what will happen? You will stop reading or watching. They don’t want that.

Their claims are high like learn python in 24-hours or learn PHP in 21 days. I know because I have read a lot of books on programming. Learning a language consume more time than 24 hours or 21 days.

Truth About Programming

I am not against the basics or ‘Hello World’ stuff. I know you have to start from basics and then progress. But many programming books and tutorials start and stop at the basic stuff.

One classic example is object-oriented design books and tutorials. They start with basics of OO programming language like the definition and syntax of class and objects. But we all know that is not related to object-oriented design.

There is a difference between object-oriented programming and object-oriented design. To differentiate between OO programming and OO design there is a phrase in the book UML Distilled by Martin Fowler.

Knowing how to use a hammer does not make you an architect.

But unfortunately, many books and tutorials do the crime of including the basic oo programming stuff in OO design books and tutorials.

They do it because OO design is hard and even harder to apply in your own projects. Hence it is not possible to attain a sense of accomplishment. Therefore they include the fluff and keep themselves in the basics and the easy stuff.

7 thoughts to “Uncomfortable Truth About Programming”

    1. Well thats the classic difference between academics & consumer market.

      If we can get every academician to practice what they preach, problem is solved.

      Marks idea if Facebook was turned down by hus own professor, talks reems of gap in accepting practical things!!

  1. Everyone must read this blog,this all provided knowledge are unique than other testing blog,Sharing very deep knowledge about object-oriented testing.
    Thanks,keep updating.

Comments are closed.