Assuming your list of animals is maintained as an instance variable for a Zoo class, and assuming the Animal class has a setWeight() method, you could do something like this:
public class Zoo {
ArrayList<Animal> animals = new ArrayList<Animal>();
//...
public void updateWeight (double weight) {
for (Animal animal:animals) {
animal.setWeight(weight);
}
}
}
The answer would be slightly different for an array of Animal, but the substance is the same.