| Run ID | 作者 | 问题 | 语言 | 测评结果 | 时间 | 内存 | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 81176 | sh25_zhangyy | 甲流病人初筛 | C++ | 通过 | 0 MS | 260 KB | 595 | 2026-01-04 15:40:51 |
#include <iostream> #include <vector> #include <string> using namespace std; struct Patient { string name; float temperature; bool cough; }; int main() { int n; cin >> n; vector<Patient> patients(n); for (int i = 0; i < n; ++i) { cin >> patients[i].name >> patients[i].temperature >> patients[i].cough; } int count = 0; for (const auto& p : patients) { if (p.temperature >= 37.5 && p.cough) { cout << p.name << endl; count++; } } cout << count << endl; return 0; }