Borderou de evaluare (job #1181510)

Utilizator cipriancxFMI - gr143 Timofte Ciprian cipriancx Data 2 mai 2014 22:10:30
Problema Tamplar Status done
Runda Arhiva de probleme Compilator cpp | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: user.cpp:9:31: error: ‘int rand [4][1000001]’ redeclared as different kind of symbol int a[1000001],rand[4][1000001]; ^ In file included from /usr/local/include/c++/4.8.0/cstdlib:72:0, from /usr/local/include/c++/4.8.0/ext/string_conversions.h:41, from /usr/local/include/c++/4.8.0/bits/basic_string.h:2817, from /usr/local/include/c++/4.8.0/string:52, from /usr/local/include/c++/4.8.0/bits/locale_classes.h:40, from /usr/local/include/c++/4.8.0/bits/ios_base.h:41, from /usr/local/include/c++/4.8.0/ios:42, from /usr/local/include/c++/4.8.0/ostream:38, from /usr/local/include/c++/4.8.0/iostream:39, from user.cpp:1: /usr/include/stdlib.h:380:12: error: previous declaration of ‘int rand()’ extern int rand (void) __THROW; ^ user.cpp: In function ‘int main()’: user.cpp:33:11: warning: pointer to a function used in arithmetic [-Wpointer-arith] rand[0][j]=x4*a[j]+rest; ^ user.cpp:33:14: warning: pointer to a function used in arithmetic [-Wpointer-arith] rand[0][j]=x4*a[j]+rest; ^ user.cpp:33:15: error: assignment of read-only location ‘*(rand + ((sizetype)j))’ rand[0][j]=x4*a[j]+rest; ^ user.cpp:33:15: error: cannot convert ‘int’ to ‘int()throw ()’ in assignment user.cpp:34:16: warning: pointer to a function used in arithmetic [-Wpointer-arith] rest=rand[0][j]/10; ^ user.cpp:34:19: warning: pointer to a function used in arithmetic [-Wpointer-arith] rest=rand[0][j]/10; ^ user.cpp:34:21: error: invalid operands of types ‘int()throw ()’ and ‘int’ to binary ‘operator/’ rest=rand[0][j]/10; ^ user.cpp:35:11: warning: pointer to a function used in arithmetic [-Wpointer-arith] rand[0][j]%=10; ^ user.cpp:35:14: warning: pointer to a function used in arithmetic [-Wpointer-arith] rand[0][j]%=10; ^ user.cpp:35:15: error: invalid operands of types ‘int()throw ()’ and ‘int’ to binary ‘operator%’ rand[0][j]%=10; ^ user.cpp:35:15: error: in evaluation of ‘operator%=(int()throw (), int)’ user.cpp:37:16: warning: pointer to a function used in arithmetic [-Wpointer-arith] if(rest){rand[0][dima+1]=rest; } ^ user.cpp:37:24: warning: pointer to a function used in arithmetic [-Wpointer-arith]

Ceva nu functioneaza?