/* The long-term evolution of species enables amphibious animals to live on land and swim in water. The virtual base class is used to establish multiple inheritance of a class, including animals (animal, attributes include body length, weight, and gender), and terrestrial animals (ter_animal, attributes increase the running speed ), aquatic Animals (aqu_animal, attributes increase the swimming speed) and amphibious animals (amp_animal ). Amphibious animals retain the attributes of terrestrial and aquatic animals. Input length, weight, gender, swimming speed, running speed (running_speed) Output initialized length, weight, gender, swimming speed, running speed (running_speed) and the length, weight, gender, swimming speed, and running speed of the input amphibious animals (running_speed) */# include <iostream> using namespace STD; class animal {protected: int height; int weight; char sex; public: Animal () {} animal (int h, int W, char S): height (H), weight (W), sex (s) {}}; class aqu_animal: virtual public animal {protected: int extends ming_speed; public: aqu_animal () {} aqu_animal (int h, int W, char S, int s_p ): animal (H, W, S), swimming_speed (s_p) {}}; class ter_animal: virtual public animal {protected: int running_speed; public: ter_animal () {} ter_animal (int h, int W, char S, int R_p): Animal (H, W, S), running_speed (R_p) {}}; class amp_animal: Public aqu_animal, public ter_animal {public: amp_animal () {} amp_animal (int h, int W, char S, int s_p, int R_p): Animal (H, W, S ), aqu_animal (H, W, S, s_p), ter_animal (H, W, S, R_p) {} void input () cin> height> weight> sex> extends ming_speed> running_speed; void show () {cout <"height:"