This commit is contained in:
HuangHai
2025-08-30 18:35:01 +08:00
commit 1f397eca87
6258 changed files with 1487241 additions and 0 deletions

27
LuoGu/RuMen/P1567.cpp Normal file
View File

@@ -0,0 +1,27 @@
#include <bits/stdc++.h>
using namespace std;
int a[1000001];
int N;
int _max = 1;
int currentmax = 1;
int main() {
cin >> N;
for (int i = 0; i < N; i++) {
cin >> a[i];
}
for (int i = 1; i < N; i++) {
if (a[i] > a[i - 1]) {
currentmax++;
} else {
if (currentmax > _max) {
_max = currentmax;
}
currentmax = 1;
}
}
cout << _max << endl;
return 0;
}