Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.
  • On a very short-lived project that I was assigned to, my primary responsibility was to port a particular astrodynamics engine to Java from C. The program had previously been ported to C from Fortran, and to Fortran from some ungodly, unknown language for an old HP paper-tape computer. I was the first actual programmer to look at said program, and all the previous ports were exactly like you described: literal translations from one language to the next.

    Function parameters were a through z. All local variables were declared like float r[412];, and used like r[53] = r[212] * r[81];. Not every index would be used, no index would be reused, and the indices were seemingly randomly chosen. All constants were handled as just numbers, many of which I was unable to track down. There was but one comment in the entire program - a four line assertion that some basic C construct did actually work. (Not that the logic worked, that the C itself was valid.)

    They quickly decided that STK [stk.com]'s engine would be money well-spent. (Perl, BTW, is their scripting language of choice.)

    • Indeed... It's funny how we all have passed through that.And that's funny how non-programmers choose their variables' names. This algorithm was gotten from an electrical circuits book and it's Portuguese title translates to "Electrical Circuits Course". Got it? No? They are teaching future engineers to write their programs in Basic and name their variables after A1, A2, A3, ..., Z7, Z8, Z9.

      It has just made me curious about what happens after Z9... Maybe AA1? ;-)

      The entry in my diary is like yours: varia
      --
      -- Godoy.