Borderou de evaluare (job #2527222)

Utilizator Anastasia11Susciuc Anastasia Anastasia11 Data 19 ianuarie 2020 20:29:19
Problema Albinuta Status done
Runda Arhiva de probleme Compilator cpp-64 | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: main.cpp:13:21: error: 'int time' redeclared as different kind of symbol int x, lcm=1, l, r, time=1; ^~~~ In file included from /usr/include/pthread.h:24:0, from /usr/include/x86_64-linux-gnu/c++/6/bits/gthr-default.h:35, from /usr/include/x86_64-linux-gnu/c++/6/bits/gthr.h:148, from /usr/include/c++/6/ext/atomicity.h:35, from /usr/include/c++/6/bits/ios_base.h:39, from /usr/include/c++/6/ios:42, from /usr/include/c++/6/ostream:38, from /usr/include/c++/6/iostream:39, from main.cpp:1: /usr/include/time.h:192:15: note: previous declaration 'time_t time(time_t*)' extern time_t time (time_t *__timer) __THROW; ^~~~ main.cpp: In function 'void build()': main.cpp:38:21: error: invalid operands of types 'time_t(time_t*) throw () {aka long int(long int*) throw ()}' and 'int' to binary 'operator%' int poz=time%lcm; ~~~~^~~~ main.cpp:43:15: error: invalid conversion from 'time_t (*)(time_t*) throw () {aka long int (*)(long int*) throw ()}' to 'int' [-fpermissive] r=time; ^~~~ main.cpp:46:22: error: invalid conversion from 'time_t (*)(time_t*) throw () {aka long int (*)(long int*) throw ()}' to 'int' [-fpermissive] used[x][poz]=time; ^~~~ main.cpp:47:16: warning: pointer to a function used in arithmetic [-Wpointer-arith] x=v[x][(time-1) % v[x].size()]; ^ main.cpp:47:19: error: invalid operands of types 'time_t (*)(time_t*) throw () {aka long int (*)(long int*) throw ()}' and 'std::vector<int>::size_type {aka long unsigned int}' to binary 'operator%' x=v[x][(time-1) % v[x].size()]; ~~~~~~~~~^~~~~~~~~~~~~ main.cpp:48:7: warning: ISO C++ forbids incrementing a pointer of type 'time_t (*)(time_t*) throw () {aka long int (*)(long int*) throw ()}' [-Wpointer-arith] time++; ^~ main.cpp:48:7: error: lvalue required as increment operand Non zero exit status: 1

Ceva nu functioneaza?