(I2
I142
I5
(dp0
Vmaxarrea.%l
p1
(Vmaxarrea.cpp
p2
S'#include<iostream>\n#include<stack>\nusing namespace std;\nstruct col\n{\n    long long h,ind;\n};\nint main(){\n    cin.tie(NULL);\n    ios::sync_with_stdio(false);\n    long long d,ans=0,n;\n    cin>>n;\n    stack<col> s;\n    col pom;\n    for(int i=0;i<n;i++)\n    {\n        cin>>d;\n        while(!s.empty()&&s.top().h>d)\n        {\n            pom=s.top();s.pop();\n            int enda;\n            if(s.empty())\n            {\n                enda=0;\n            }\n            else\n            {\n                enda=s.top().ind+1;\n            }\n            ans=max(ans,(i-enda)*(pom.h));\n        }\n        pom.ind=i;\n        pom.h=d;\n        s.push(pom);\n    }\n    while(!s.empty())\n    {\n        pom=s.top();s.pop();\n        int enda;\n        if(s.empty())\n        {\n            enda=0;\n        }\n        else\n        {\n            enda=s.top().ind+1;\n        }\n        ans=max(ans,(n-enda)*(pom.h));\n    }\n    cout<<ans<<"\\n";\n    return 0;\n}\n'
p3
tp4
stp5
.