Example #1
0
  /**
   * @param age
   * @param name
   * @param language
   */
  public Human(int age, String name, ArrayList<Language> language) {

    this.age = age;
    this.name = name;
    this.language = language;
    Human.setAgeSum(Human.getAgeSum() + age);
    Human.setInstanceCount(Human.getInstanceCount() + 1);
    putInLanguageCollection();
  }
Example #2
0
 @Override
 public float getMiddleAge() {
   // TODO Auto-generated method stub
   return (Human.getAgeSum() / Human.getInstanceCount());
 }