[Tutor] Should I create a Class for this?

Brad Chandler mbc2@netdoor.com
Tue, 12 Dec 2000 11:33:14 -0600


Where I work, we have a report which performs a number of calculations on
each employee to determine the exact amounts of his salary and fringe
benefits.  I've put all of these calculations into a python file, defining
each as a separate function.  There are approximately 67 functions and about
50 constant variables that I've defined at the top of the file.

What is the best way to organize these functions so that I can easily reuse
them in different programs?  Should I create a class and put them in it.
I've never created a class before so I'm not exactly sure how to go about
it.  As it is right now, I can just import the file and access the
functions.  What would be the advantage of creating a class for this?

Brad