Problem area2
User PyAce
Submission Time 2026-02-23 16:27:32
Score 0
Max Time N/A
Max Memory N/A

Compile Error

area2.cpp: In function ‘int main()’:
area2.cpp:9:2: error: expected initializer before ‘for’
9 | for (int i=0;i<n;i++) {
| ^~~
area2.cpp:9:15: error: ‘i’ was not declared in this scope
9 | for (int i=0;i<n;i++) {
| ^
area2.cpp:14:7: error: ‘d’ was not declared in this scope
14 | sort(d.begin(), d.end(), greater<int>())
| ^
area2.cpp:16:2: error: ‘y’ was not declared in this scope
16 | y = d[1];
| ^
area2.cpp:17:11: error: ‘x’ was not declared in this scope
17 | cout << (x * y);
| ^