So the ghost of programmers past has paid me a visit.
I am replicating an analysis piece that I had written back in high school. I have some of the original outputs generated but none of the original code. And as we'd be talking Pascal on the Commodore 64 vs Objective C on the iOS platforms, I could care less about original code.
There is, however, a trick on the analysis. I distinctly remember completely glossing over the problem when I was a teenager - it was a complicated problem, it didn't lend itself to a quick answer, it was going to be icky code ... WHINE WHINE WHINE. I threw something in to approximate the correct answer and moved on. As the output was really only for myself and an immediate circle of friends I thought this was an acceptable answer.
Unfortunately, when code monkeys take shortcuts, real people end up becoming monkeys.
The whole point to a computer program running calculations is ensuring the end user doesn't have to. The computer SHOULD BE the monkey - it can run the numbers much faster, and to a greater precision, than any other primate. Worse, when the calculations might take a human tens of minutes, the human will "guess-timate" and apply emotion in place of logic.
How many computer programs can you think of where it's clear that the programmer decided to get a latte instead of spending some extra time to finish the job properly?
How many times have you done calculation tasks FOR the computer instead of ON the computer?
Want a banana?
So ... it took around 2 to 3 hours to write that tricky piece of code last night. About half that time was spent staring out the window trying to wrap my head around the next part of the problem. I think the end result is pretty cool - it appears as effortless and graceful as a samurai's kata and will be about as difficult as one to replicate.
Truly, some excellent kung-fu. Take that, young-code-monkey-me!
No comments:
Post a Comment