Re: TAS 2006 Point Standing Hi Stephen,
Before my program is run, I have to create text files with contest results. The result files are stored in seperate directories based on regions (SW,NW,SC,NC, etc...). I can do it very quicky by cutting and pasting the result from website. The content of result in the text file looks like:
Stephen Hamilton
Michael Jackson
George Bush
When the program runs, it reads Pilot name from the file. First one is first place; second one is second place, and so on.... It allocates one structure (memory) dynamically for each pilot and links them together as a single linked list as it goes. Each structure contains points earned per contest, pilot name, etc... When it finishes reading the files (end of file - feof()), program knows how many pilots are in that contest and pilot placements. It then calculates TAS points based on the specified criterions. Finally, it sorts the linked link based on the TAS points in decending order and display them. It does other things as well but this should give you some ideas.
Writing the program took me a few hours. Including one contest to the point standing doesn't take more than 2 minutes. Sometimes, it takes longer for me to do this when pilots use different names in different contests (David Moser and Dave Moser, Mike Elder and Michael Elders). I have to spot these discrepencies manually and then correct these in the contest result files.
Writing this program is easier than doing a "0 of 8" or "0 of 16" maneuver. :-)
I will try to update the list whenever result is available from now to July 31.
I hope it helps.
__________________ Kevin Tran Composite-ARF SuperXtra 3.1m Composite-ARF YAK 55SP 3.0m
Last edited by Kevin Tran : 05-25-2006 at 05:31 PM.
|