[Tutor] Hay Variables

christopher.henk at allisontransmission.com christopher.henk at allisontransmission.com
Fri Sep 12 20:13:50 CEST 2008


I would use a list of grades and the length of the list.

Chris




"Jeremiah Stack" <nnolie at gmail.com> 
Sent by: tutor-bounces+christopher.henk=allisontransmission.com at python.org
09/12/2008 02:08 PM

To
"Python Tutor" <tutor at python.org>
cc

Subject
[Tutor] Hay Variables






Sorry,


Okay,
Say i want to calculate the average for Math = 91 Science = 97 and English 
= 96, 

I Declare a variable = Number of classes to divide by.

So instead say later I want to add another class.

Instead of adding a variable And changing the (Number of Classes = 3) 
variable.

I would like to just add another variable and have the Number of classes 
variable change automatically.

So NumberOfClasses = (Number variables).

Hope that makes sense and without user keyboard input
_______________________________________________
Tutor maillist  -  Tutor at python.org
http://mail.python.org/mailman/listinfo/tutor

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/tutor/attachments/20080912/afd57eb9/attachment.htm>


More information about the Tutor mailing list