提交时间:2024-10-27 08:34:08

运行 ID: 54288

#include<bits/stdc++.h> using namespace std; int main(){ int n, h, l, c = 0, s = 0; cin >> n; for(int i = 0; i < n; i++){ cin >> h >> l; if(h >= 90 && h <= 140 && l >= 60 && l <= 90){ c++; if(c > s){ s = c; } }else{ c = 0; } } cout << s; return 0; }