Borderou de evaluare (job #1725884)

Utilizator IliesiDanielDaniel IliesiDaniel Data 6 iulie 2016 17:16:56
Problema Divizori Status done
Runda Arhiva de probleme Compilator cpp | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: user.cpp:7:29: error: ‘long unsigned int div [707]’ redeclared as different kind of symbol unsigned long n = 0, div[707], fact[707], i = 0, j = 0, st[707], oc[707], nr = 0, da = 0, Nf = 0; ^ In file included from /usr/include/c++/4.8/cstdlib:72:0, from /usr/include/c++/4.8/ext/string_conversions.h:41, from /usr/include/c++/4.8/bits/basic_string.h:2815, from /usr/include/c++/4.8/string:52, from /usr/include/c++/4.8/bits/locale_classes.h:40, from /usr/include/c++/4.8/bits/ios_base.h:41, from /usr/include/c++/4.8/ios:42, from /usr/include/c++/4.8/ostream:38, from /usr/include/c++/4.8/iostream:39, from user.cpp:1: /usr/include/stdlib.h:785:14: error: previous declaration of ‘div_t div(int, int)’ extern div_t div (int __numer, int __denom) ^ user.cpp: In function ‘void det(long unsigned int)’: user.cpp:29:28: warning: pointer to a function used in arithmetic [-Wpointer-arith] a = div[st[k-1]]; ^ user.cpp:29:28: error: invalid conversion from ‘div_t (*)(int, int)throw ()’ to ‘long unsigned int’ [-fpermissive] user.cpp:30:22: warning: pointer to a function used in arithmetic [-Wpointer-arith] b = div[i]; ^ user.cpp:30:22: error: invalid conversion from ‘div_t (*)(int, int)throw ()’ to ‘long unsigned int’ [-fpermissive] user.cpp:65:41: warning: pointer to a function used in arithmetic [-Wpointer-arith] fout<<div[st[da]]<<" "; ^ user.cpp: In function ‘int main()’: user.cpp:92:21: warning: pointer to a function used in arithmetic [-Wpointer-arith] div[++nr]=i; ^ user.cpp:92:22: error: assignment of read-only location ‘*(div + ((sizetype)(++ nr)))’ div[++nr]=i; ^ user.cpp:92:22: error: cannot convert ‘long unsigned int’ to ‘div_t(int, int)throw ()’ in assignment user.cpp:101:25: warning: pointer to a function used in arithmetic [-Wpointer-arith] div[++nr]=n/i; ^ user.cpp:101:26: error: assignment of read-only location ‘*(div + ((sizetype)(++ nr)))’ div[++nr]=n/i; ^ user.cpp:101:26: error: cannot convert ‘long unsigned int’ to ‘div_t(int, int)throw ()’ in assignment

Ceva nu functioneaza?