25 years of programming

March 8, 2008 at 11:01 am | Posted in Programming, Ramblings | 6 Comments

I started programming in 1983 on a Sharp PC-1251 with an amazing 3486 bytes RAM. It had a Basic interpreter and we had to use it for a Calculus course at the university.

Sharp PC-1251

So that’s 25 years ago. That made me suddenly wonder how much code in different programming languages I have written in all those years. A completely useless question of course, but fun nevertheless. I don’t have all the code available anymore so I have to estimate some numbers from memory. The numbers I present include comment and blank lines.

The list:

  1. C: 100.000
  2. C#: 70.000
  3. Java: 20.000
  4. C++: 20.000
  5. Pascal: 5.000
  6. PV~Wave: 5.000
  7. Basic: 2.000
  8. Matlab: 1.000
  9. Lisp/Scheme: 1.000
  10. Assembly: 1.000
  11. Fortran: 200
  12. Perl: 100
  13. Python: 20
  14. Boo: 20
  15. Nemerle: 20
  16. F#: 20
  17. Ruby: 10

This totals 225k lines of code in 25 years.In other words, about 10k LOC’s per year, or 30 lines per day. Other interesting questions that could be asked:

  • how much of this code is still in use
  • how much of this code is forever lost
  • how much of this code is still archived somewhere on a company network
  • how much code would this have been if it all had been written using language xyz
  • how many bugs did I introduce over the last 25 years 😉


RSS feed for comments on this post. TrackBack URI

  1. So which is your favourite?
    Can you order it chronologically?
    Does it include code you wrote but discarded on the way to used code?

  2. > So which is your favourite?

    Hm, tricky question. Only correct answer I guess would be “it depends”. I have some strong dislikes like Fortran and Basic. And obviously building enterprise software with Matlab is not going to work, but it’s great for simulations. I’m fond of functional languages because of their elegance. For desktop software I would almost certainly pick C#. Personally I don’t think there is that much fundamental difference between C# and Java, but I like the syntactical sugar that C# offers me.

    > Can you order it chronologically?

    1983 – 1985: basic, pascal, fortran, assembly
    1985 – 2003: C, Lisp, Scheme
    1990 – 2000: C++, PV~Wave, Matlab, Perl
    1996 – now: Java
    2004 – now: C#
    2007 – now: Python, Ruby, Nemerle, Boo

    > Does it include code you wrote but discarded on the way to used code?

    No, this is just the end result. Usually I refactor a lot, so the total number of LOCs I ever wrote could easily be 20 – 50 % more.

    Nice questions, thanks 🙂

  3. may be offtopic here but i don’t know how to contact you in other way (in case you are not following the late replies to your last question on GT )

    another link that may be useful to duplicate PS layer merging mode

  4. @photocomix: thanks for the info! You can always contact me directly at maurits.rijk@gmail.com

  5. Judging from these statistics you are obviously, in the great scheme of things, a C-novice and a Ruby-expert 😉

  6. […] with the Google Graph API March 26, 2009 at 9:05 pm | In Programming | In 25 years of programming I blogged about the lines of code I have written in several programming languages. I am […]

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Blog at WordPress.com.
Entries and comments feeds.

%d bloggers like this: