动物名字,选择判断语句
作者:
寄雾.
,
2024-11-13 18:06:50
,
所有人可见
,
阅读 2
#include <iostream>
using namespace std;
int main() {
string a, b, c;
cin >> a >> b >> c;
if (a == "vertebrado") {
if (b == "ave") {
if (c == "carnivoro")
cout << "aguia" << endl;
else
cout << "pomba" << endl;
}
else {
if (c == "onivoro")
cout << "homem" << endl;
else
cout << "vaca" << endl;
}
}
else {
if (b == "inseto") {
if (c == "hematofago")
cout << "pulga" << endl;
else
cout << "lagarta" << endl;
}
else {
if (c == "hematofago")
cout << "sanguessuga" << endl;
else
cout << "minhoca" << endl;
}
}
return 0;
}