How does homeostasis help the survival of an organism?