Borderou de evaluare (job #1674712)
Utilizator | Data | 4 aprilie 2016 20:21:45 | |
---|---|---|---|
Problema | Range minimum query | Status | done |
Runda | Arhiva educationala | Compilator | cpp | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
user.cpp:9:14: error: ‘int log [100003]’ redeclared as different kind of symbol
int log[N_MAX];
^
In file included from /usr/include/features.h:357:0,
from /usr/include/stdio.h:28,
from user.cpp:1:
/usr/include/i386-linux-gnu/bits/mathcalls.h:110:1: error: previous declaration of ‘double log(double)’
__MATHCALL (log,, (_Mdouble_ __x));
^
user.cpp: In function ‘int main()’:
user.cpp:26:26: warning: pointer to a function used in arithmetic [-Wpointer-arith]
int l = log[b-a+1];
^
user.cpp:26:26: warning: pointer to a function used in arithmetic [-Wpointer-arith]
user.cpp:26:26: error: invalid conversion from ‘double (*)(double)throw ()’ to ‘int’ [-fpermissive]
user.cpp: In function ‘void calcLog()’:
user.cpp:55:10: warning: pointer to a function used in arithmetic [-Wpointer-arith]
log[1] = 0;
^
user.cpp:55:12: error: assignment of read-only location ‘*(log + 1u)’
log[1] = 0;
^
user.cpp:55:12: error: cannot convert ‘int’ to ‘double(double)throw ()’ in assignment
user.cpp:56:39: warning: pointer to a function used in arithmetic [-Wpointer-arith]
for (int i = 2; i <= n; ++i) log[i] = log[i/2] + 1;
^
user.cpp:56:50: warning: pointer to a function used in arithmetic [-Wpointer-arith]
for (int i = 2; i <= n; ++i) log[i] = log[i/2] + 1;
^
user.cpp:56:54: warning: pointer to a function used in arithmetic [-Wpointer-arith]
for (int i = 2; i <= n; ++i) log[i] = log[i/2] + 1;
^
user.cpp:56:41: error: assignment of read-only location ‘*(log + ((sizetype)i))’
for (int i = 2; i <= n; ++i) log[i] = log[i/2] + 1;
^
user.cpp:56:41: error: cannot convert ‘double (*)(double)throw ()’ to ‘double(double)throw ()’ in assignment
user.cpp: In function ‘int main()’:
user.cpp:24:30: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%d%d", &a, &b);
^
user.cpp: In function ‘void citire()’:
user.cpp:34:34: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result]
freopen("rmq.in", "r", stdin);
^
user.cpp:35:36: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result]
freopen("rmq.out", "w", stdout);
^
user.cpp:37:26: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%d%d", &n, &m);
^
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !