Python classes

Here's a python class example that follows this question prompt:

''Write class fruit. Class fruit has three varibles: type, weight, and isFresh.

It has three functions: a constructor, a printInfo function, and turnRotten.

The constructor takes two parameters, t and w, which are set to type and weight. isFresh is always set to True.

The printInfo function just prints the contents of all the variables, and the turnRotten function sets isFresh to False.

Instantiate two fruits, print out their information, turn them rotten, and reprint.''