Computer Science Canada Help |
Author: | Thanos [ Mon Sep 09, 2002 8:46 pm ] |
Post subject: | Help |
Hey guys, I need some help with this thing im working on. It's the beginning of school so don't worry, this is not a school project. I'm just trying to get ahead in class. Anyway, my question is what is the code for averaging a bunch of numbers? what's the code for sum? I'm trying to create a program that will average some school marks. Thanks for taking your time to read this. 8) |
Author: | Dan [ Tue Sep 10, 2002 10:47 am ] | ||||
Post subject: | help | ||||
ok here is a progame that will avg any number of numbers:
now i dont know how much you know about turing so here are some of the basciks: to add numbers:
avg is done like in math by adding the numbers up then diveding by the amout of nums. if you need any more help or anything fell free to post any time. |
Author: | Tony [ Tue Sep 10, 2002 4:51 pm ] |
Post subject: | grr |
Dan, its the beginning of school and the guy is asking you how to add numbers? You just give him some code with for loops and no documentary... Could have used arrays as well Well just keep in mind that you got to remember at what knowledge level people are. As for Thanos, good luck with your programming Dan will be posting some 'insparational' source code up on the board cuz I'LL BE DOING VB instead. Oh, Dan, nice quote you got there... BTW, I'm fine now |
Author: | Dan [ Tue Sep 10, 2002 7:30 pm ] | ||||||||
Post subject: | sory | ||||||||
ok, may be i shode have made it more basick. ok here is some math stuff in turing: + add's two numbers - subtractes two numbers := asings a value to a var += adds a number to a var -= subtraces a number from a var div diveds a number by another * mutiplyes a number by another puting it togther: lets say we whont to disay an awers to 5 + 5 on the screen, we coude do this:
to add two vars together and put it on the screen you coude do this:
to add two vars together and soter that number in a var:
all this can be done the same using +, -, *, /, and div so to do a simpe version of the avg thing you can do this:
ok, if you have any more quesions about this plz post. p.s. is that ok with you tony, lol |
Author: | Thanos [ Fri Sep 13, 2002 5:06 pm ] |
Post subject: | |
Hey guys, thanks for all the help. |