Caso # | Resultado | Tiempo | Memoria |
---|---|---|---|
#1 |
Error de compilación
main.cpp:19:24: error: expected ';' in 'for' statement specifier for (int i = 0; i < n) { ^ main.cpp:27:12: error: expected '}' return 0; ^ main.cpp:4:16: note: to match this '{' int main(void) { ^ 2 errors generated. |
||
#2 |
Error de compilación
main.cpp:19:24: error: expected ';' in 'for' statement specifier for (int i = 0; i < n) { ^ main.cpp:27:12: error: expected '}' return 0; ^ main.cpp:4:16: note: to match this '{' int main(void) { ^ 2 errors generated. |
||
#3 |
Error de compilación
main.cpp:19:24: error: expected ';' in 'for' statement specifier for (int i = 0; i < n) { ^ main.cpp:27:12: error: expected '}' return 0; ^ main.cpp:4:16: note: to match this '{' int main(void) { ^ 2 errors generated. |
||
#4 |
Error de compilación
main.cpp:19:24: error: expected ';' in 'for' statement specifier for (int i = 0; i < n) { ^ main.cpp:27:12: error: expected '}' return 0; ^ main.cpp:4:16: note: to match this '{' int main(void) { ^ 2 errors generated. |
||
#5 |
Error de compilación
main.cpp:19:24: error: expected ';' in 'for' statement specifier for (int i = 0; i < n) { ^ main.cpp:27:12: error: expected '}' return 0; ^ main.cpp:4:16: note: to match this '{' int main(void) { ^ 2 errors generated. |
||
#6 |
Error de compilación
main.cpp:19:24: error: expected ';' in 'for' statement specifier for (int i = 0; i < n) { ^ main.cpp:27:12: error: expected '}' return 0; ^ main.cpp:4:16: note: to match this '{' int main(void) { ^ 2 errors generated. |
||
#7 |
Error de compilación
main.cpp:19:24: error: expected ';' in 'for' statement specifier for (int i = 0; i < n) { ^ main.cpp:27:12: error: expected '}' return 0; ^ main.cpp:4:16: note: to match this '{' int main(void) { ^ 2 errors generated. |
||
#8 |
Error de compilación
main.cpp:19:24: error: expected ';' in 'for' statement specifier for (int i = 0; i < n) { ^ main.cpp:27:12: error: expected '}' return 0; ^ main.cpp:4:16: note: to match this '{' int main(void) { ^ 2 errors generated. |
||
#9 |
Error de compilación
main.cpp:19:24: error: expected ';' in 'for' statement specifier for (int i = 0; i < n) { ^ main.cpp:27:12: error: expected '}' return 0; ^ main.cpp:4:16: note: to match this '{' int main(void) { ^ 2 errors generated. |
||
#10 |
Error de compilación
main.cpp:19:24: error: expected ';' in 'for' statement specifier for (int i = 0; i < n) { ^ main.cpp:27:12: error: expected '}' return 0; ^ main.cpp:4:16: note: to match this '{' int main(void) { ^ 2 errors generated. |
#include <iostream> using namespace std; int main(void) { int n; cin>>n; long long a[n]; for (int i = 0; i < n; i++) { cin>>a[i]; } int q; cin>>q; long long p; for (int i = 0; i < q; i++) { cin>>p; int count = 0; for (int i = 0; i < n) { if (a[i] > p) { count++; } } cout<<count<<endl; } return 0;