Computer Science Canada Calculations off...Running Total |
Author: | Hunter007 [ Tue Jan 20, 2004 7:33 pm ] | ||
Post subject: | Calculations off...Running Total | ||
OK I know that I need to have a running total to keep track of the numbers and I posted a question similiar to this before. However when I tryed to impliment it, it didn't work I did what I thought was supposed to be done, but the calculations aren't working.
Any help would be greatly appreciated. |
Author: | shorthair [ Tue Jan 20, 2004 7:37 pm ] |
Post subject: | |
When i did my payroll system i made a record of the main waraiables like the name and employee number and sin # you have to store these values in a " Binary file" that can be read written , modded , seeked and told , thats how you do this program propery ,save the values for later use this method is very easy once you learn how ot make a record , Your calculations are wrong becuase you are breaking the 3 rule of programming SEQUENCE , if you trace your program you will see that your variables are changing and when they do , your calculations go off you need to make sure you do your calculations in the correct order |
Author: | AsianSensation [ Tue Jan 20, 2004 8:45 pm ] |
Post subject: | |
shorthair wrote: you need to make a record of the main waraiables like the name ans stuff
not really, structures are just ways of organizing a person's code. It's perfectly fine to not use structures and still be able to do a good program. I know forgot to use structures for my FP last year. It basicly depends on how well you can keep track of stuff yourself. If you are really good, then you can just declare every single variable as one big array. But then again, that requires a great amount of mental discipline |
Author: | Thuged_Out_G [ Tue Jan 20, 2004 10:32 pm ] | ||||
Post subject: | |||||
using a record for this would make things much easier to organize
you store data in it like such
|