in reply to Sub routines

Your code is pretty much impossible for me to decipher its purpose. You've posted questions here multiple times, and each time monks have attempted to figure out you're trying to do to little avail:

I've read each of those, and nowhere do you try to explain your project in English.

Anytime someone is coding something, they should be able to explain it in words before they dive into coding. It would really help us if you were to explain what you're code is trying to accomplish. What is your data and how are you trying to process it?

Replies are listed 'Best First'.
Re^2: Sub routines
by velocitymodel (Acolyte) on Mar 31, 2011 at 14:44 UTC

    Sorry about the confusion. I will definitely try and work that out in for myself. Thanks for the advice.

      Hi Mate,

      My advice is not that you go and just solve your own problem. It's that you try to explain to us what you're doing before showing us code. You've been working on this "project" for a while now so it's apparent that you're trying to accomplish something. However, given the number of consistent errors in your code even without knowing what it's doing, maybe it's time to start over?

      Share a description of your project in english, and let us guide you toward the right way of accomplishing it.

        What I have is a file with about 17,000 "events" for earthquake arrival times. One event looks something like this.

        82 2 22 1043 54.7 48.020 114.037 17.5 3.2 2.9 13 177 84.3 0.20 +1.6 2.7 C MBMG * 3.1 KALISPELL VALLEY; FELT 3.07 82022210 BUT EP4432.804ES60.7 LRM IPD4435.40 IS67.2 180. AMM IPD4429.50 ES57.3 133. MSO EPC4415.90 ES32.3 CMT EP4430.50 IS58.3 LDM IPC4412.20 ES24.3 3 RXF EPC4414.3 CLX IPC4408.70 ES19.7

        As mentioned before there are about 17,000 of these events and they are all of different length but the same format. I want to take the header of each event and break it up and assign variables to the information I need. I then want to keep some of the variables at the heading of the event and move the rest to the end of the event in a specified order. For the body of the event I simply want to delete extraneous information. I then want to print this new format out to a seperate file so that it may be used in another software program. So my over all goal is to format my original file into a new format to run in the software. This is what my events should look like

        13 BUT 4432.804 60.7 LRM 4435.40 67.2 AMM 4429.50 57.3 MSO 4415.90 32.3 CMT 4430.50 58.3 LDM 4412.20 24.3 3 RXF 4414.3 CLX 4408.70 19.7 1043 54.7 114.037 48.020 17.5 3.2 177

        Right now with my code I am just trying to focus on rearranging my variables and place them correctly.I hope this clears things up.