Pagini recente » Borderou de evaluare (job #1530482) | Borderou de evaluare (job #2720981) | Borderou de evaluare (job #3261768) | Monitorul de evaluare | Borderou de evaluare (job #2604609)
Borderou de evaluare (job #2604609)
Raport evaluator
Compilare:
main.cpp: In function 'void Add(int, int)':
main.cpp:9:26: warning: suggest parentheses around arithmetic in operand of '^' [-Wparentheses]
#define zeros(x) (x^(x-1)&x)
~~~~~^~~~
~
int n,poz[N],aib[N],a[N],b[N];
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~
void Add(int p , int q)
~~~~~~~~~~~~~~~~~~~~~~~~
{
~~
int i;
~~~~~~~
for(i=p;i<=n;i+=zeros(i))
~~~~~~~~~~~~~~~~~~~~~~~
main.cpp:16:21: note: in expansion of macro 'zeros'
for(i=p;i<=n;i+=zeros(i))
^~~~~
main.cpp: In function 'int Get(int)':
main.cpp:9:26: warning: suggest parentheses around arithmetic in operand of '^' [-Wparentheses]
#define zeros(x) (x^(x-1)&x)
~~~~~^~~~
~
int n,poz[N],aib[N],a[N],b[N];
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~
void Add(int p , int q)
~~~~~~~~~~~~~~~~~~~~~~~~
{
~~
int i;
~~~~~~~
for(i=p;i<=n;i+=zeros(i))
~~~~~~~~~~~~~~~~~~~~~~~~~~
aib[i]+=q;
~~~~~~~~~~~
}
~~
int Get(int p)
~~~~~~~~~~~~~~~
{
~~
int i;
~~~~~~~
int rez=0;
| Test |
Timp executie |
Memorie folosita |
Mesaj |
Punctaj/test |
| 1 | 2ms | 131kb | OK | 10 |
| 2 | 2ms | 131kb | OK | 10 |
| 3 | 3ms | 131kb | OK | 10 |
| 4 | 3ms | 131kb | OK | 10 |
| 5 | 3ms | 131kb | OK | 10 |
| 6 | 2ms | 131kb | OK | 10 |
| 7 | 2ms | 131kb | OK | 10 |
| 8 | 59ms | 1703kb | OK | 10 |
| 9 | 59ms | 1703kb | OK | 10 |
| 10 | 317ms | 1703kb | Incorect | 0 |
| Punctaj total | 90 |