Wednesday, October 7, 2009

Programming Wisdom

After a three hour battle with passing variables around in C++ (as I was encapsulating my previously global development variables), I came up with a pretty philosophical sounding summary of my experience:

"One does not truly understand passing by reference until he
first does truly not understand it."

Tiell, 2009 A.D.

Neat. Now, enough of that. What I really mean is, that during my development tonight I came across a situation where passing a variable by reference was the obvious course of action. However, I completely forgot to even attempt it. So I sat here thinking about it for nearly three hours. During those three hours, I basically came up with the basic underlying idea of passing a variable by reference. It wasn't until then that I realized, "Oh, that functionality is already built in." This is a reoccurring theme I think. You can spend a lot of time on a great idea, but then come to realize that it has already been developed. It's bittersweet, but much more sweet I think. You can just throw that functionality into your library and move on to the next big thing. Assuming that it too, hasn't already been developed.

C++, my dear old friend. It's good to be back.



Yeah. It was that simple. You don't want to see what I tried to make this work!

2 comments:

  1. Don't you love C++!

    It really is a great way of learning programming, atleast you aren't doing it in DOS! LoL.

    I can't wait to remember all the things PHP can do.

    ReplyDelete
  2. Heh, yeah. It would be a different story without a modern compiler.

    ReplyDelete