Borderou de evaluare (job #1950630)

Utilizator muresanvladMuresan Vlad muresanvlad Data 3 aprilie 2017 10:37:26
Problema Muzeu Status done
Runda Arhiva de probleme Compilator cpp | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: user.cpp: In function ‘void citire()’: user.cpp:22:22: warning: format ‘%s’ expects argument of type ‘char*’, but argument 2 has type ‘char (*)[255]’ [-Wformat=] scanf("%s",&s); ^ user.cpp:24:34: error: incompatible types in assignment of ‘int’ to ‘int [255]’ if (s[j]=='#') a[j+1]=-1; ^ user.cpp:27:27: error: incompatible types in assignment of ‘int’ to ‘int [255]’ a[j+1]=1; ^ user.cpp: In function ‘void bordare()’: user.cpp:41:1: error: incompatible types in assignment of ‘int’ to ‘int [255][255]’ =-1; ^ user.cpp:42:15: error: incompatible types in assignment of ‘int’ to ‘int [255]’ a[n+1]=-1; ^ user.cpp:43:13: error: incompatible types in assignment of ‘int’ to ‘int [255]’ a[0]=-1; ^ user.cpp:44:15: error: incompatible types in assignment of ‘int’ to ‘int [255]’ a[n+1]=-1; ^ user.cpp: In function ‘void Lee()’: user.cpp:58:21: error: invalid conversion from ‘int*’ to ‘int’ [-fpermissive] cx.l=t.l+dx; ^ user.cpp:59:21: error: invalid conversion from ‘int*’ to ‘int’ [-fpermissive] cx.c=t.c+dy; ^ user.cpp: In function ‘void afisare()’: user.cpp:77:32: warning: format ‘%d’ expects argument of type ‘int’, but argument 2 has type ‘int*’ [-Wformat=] printf("%d ",a[j]-1); ^ user.cpp: In function ‘void citire()’: user.cpp:16:34: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result] freopen("muzeu.in","r",stdin); ^ user.cpp:17:36: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result] freopen("muzeu.out","w",stdout); ^ user.cpp:18:19: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result] scanf("%d",&n); ^ user.cpp:22:23: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result] scanf("%s",&s); ^

Ceva nu functioneaza?