Learning from Existing Code



Another question from a software developer:

What kind of things can you learn from a guy who only hacks existing code?
At my previous job I was the lead programmer and I worked with this guy who was a self-admitted hacker. We respected each other and had a great relationship. The company was much better off because we blended our talents.

I would tend to look for an elegant, graceful solution that we could add to our code library. He would tend to find, tweak, and fit some strange piece of code into a solution. One of the most valuable lessons I learned from him was you don’t always have to build the solution from scratch, there’s a ton of code out there you can borrow from.

What kind of things have you learned from a hacker?

Definition: By hacker I mean someone who for the most part, cannot create something from scratch. However they are very good at morphing code that others have written.

Well, I learned a lot of programming by hacking, in the old definition, as in someone who takes stuff apart and tries to make it do more stuff. In my case, I reverse-engineered file formats for program code for a programming language that no longer exists–that was Texas Instruments Extended BASIC for the TI/994a Home Computer, back in the 1980’s. Pulling that information apart and understanding the proprietary format allowed me to write programs that modified programs, mostly to make them easier to edit; there are still online copies of that around, if you search online for ‘MICROpendium Magazine’ and the program called ‘SubIndex’. It was great training.

Now, most companies specifically prohibit reverse-engineering of their products, so when it’s done, it doesn’t get published. What’s evolved since then has been more along the lines of code sample collections on the various crowd-sourced programming language how-to sites. There are work-arounds of just about any problem you can think of, and many, many of these cover topics that the official sites for the products involved won’t cover at all because they don’t want to endorse a solution that they haven’t tested in-house.

As a programming approach, I’ve always saved every chunk of code as a function or a subprogram. And then reuse code, over and over. And I pull code out of my web sites to use on my other sites just about every month. It saves time.

Yes, I’ve gone your way, and written elegant recursive code that did the impossible in one page. But that’s too much like work for most quick tasks. A quick assembly of saved parts and my prior projects is the preferred approach for me.

Jerry Stern
Chief Technology Officer, PC410.com

BackBlaze

Definition: Hacker

Another software developer question:

I’m wondering if the term Hacker means different things to different people. When most people hear the word hacker what are the first things that come to mind?

Hacker, back in the early days of PCs, originally meant someone who climbed into the internals of technology to make it do more stuff. In hardware, we would take an IBM diskette drive, test what happened with every jumper setting, maybe add a DIPP switch to make testing easier, and then hook up the result to a Texas Instruments 99/4a computer, where it was never designed to go. Or read program files from diskettes in pure binary format and match up numbered commands with programming symbols to make programs that could modify programs, usually to add formatting and fix line numbering. Then, it was all positive, and “no reverse engineering allowed” statements hadn’t evolved yet.

NOW, hacker is used more in the negative sense, like cracker, which generally includes creation of cheat codes, bypassing sections of code for various reasons, and so on.

The way technology words enter the mainstream vocabulary is mostly through television and movies, and Hollywood is nearly as sloppy with tech words as the evening news, so ‘hacker’ is mostly used in the negative sense by most of the mainstream media. But a hacker isn’t inherently evil.

Jerry Stern
Chief Technology Officer, PC410.com

What are the major challenges you face as a micro-ISV?

Another question from a software developer:

As a one-person independent software developer, what are the major challenges you faced? How did you
overcome these challenges?

There was a time before the internet, yes, even before it was still ‘The Internet’, when being a one-person development company meant you worked alone. Wrote code, wrote letters to customers, on actual paper and snail mail, did your own artwork, everything. The result was a very real reluctance to allow ANY part of a project to be done elsewhere.

That’s over. Now, our programs & apps have to run alongside other programs, share data with other users of the same apps, check for updates, sell upgrades (and power-ups), and be visually stunning and immediately obvious to use without a bound instruction manual. It’s too much. You can’t do that alone; you can’t even visualize it without loads of feedback from experts in each area.

We can outsource graphics. Or web sites, animation, speech recording, writing, even blocks of code, if it gets the project done. Now, it’s a management job, rather than doing every little piece of the project in-house. You don’t need employees, but you do need trusted partners to do the tasks you will (reluctantly) admit that you can’t do yourself in a reasonable time. Or just don’t wanna.

So does that mean hire outsource help? You could. Or if you work with other programmers, or know programmers from the ASP, you can offer to trade technical expertise for help in other areas.

Jerry Stern
Chief Technology Officer, PC410.com