Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
113842 罗子童 找错误 C++ Accepted 15 MS 464 KB 544 2025-03-16 18:19:24

Tests(10/10):


Code:

#include<iostream> // cin\cout\endl #include<cstdio> //scanf()\printf() #include<cstring> // strcpy()\strcat()\strcmp()\strlen()\memset() #include<cmath> //sqrt()\pow()\abs()\ceil()\floor()\max()\min() using namespace std; int main(){ int max=0,s=0,n; cin>>n; int a[50001]; for(int j=0;j<n;j++){ cin>>a[j]; } for(int j=0;j<n;j++){ if(a[j]>=max){ max=a[j]; } else{ s++; } } cout<<s; return 0; }