title: Find the total number of students
body: <p>I have a parent class called StudentBody and a child class called MathStudentBody. My question is how can i explained the child class so as to find the total number of students in the class? I guess we have to find out the total number of objects created ? Can anyone point me to the right direction</p>
  
  <pre><code>class StudentBody:
  
      count = 0
      def __init__(self, name,gender,year,gpa):
          self.name = name
          self.gender = gender
          self.year = year
          self.gpa = gpa
          self.count+= 1
  
      def IsFreshman(self):
          print "I am the StudentBody method"
          if self.year == 1:
              return True
          else :
              return False
  
      def countTotal(self):
          return self.count
  
  class MathStudentBody(StudentBody):
  
      def __init__(self,name,gender,year,gpa,mathSATScore):
          #super(MathStudentBody,self).__init__(name,gender,year,gpa)
          StudentBody.__init__(self,name,gender,year,gpa)
          self.MathSATScore = mathSATScore
  
      def IsFreshman(self):
          print "I am the MathStudentBody method"
  
  
      def CombinedSATandGPA(self):
          return self.gpa*100 + self.MathSATScore
  
      def NumberOfStudents(self):
          return
  </code></pre>