Borderou de evaluare (job #2216664)

Utilizator NOSCOPEPROKENDYMACHEAMACUMVREAU NOSCOPEPROKENDY Data 27 iunie 2018 16:31:47
Problema Figuri2 Status done
Runda Arhiva de probleme Compilator cpp | Vezi sursa
Scor 100

Raport evaluator

Compilare: user.cpp: In function ‘int main()’: user.cpp:21:9: warning: ‘char* gets(char*)’ is deprecated [-Wdeprecated-declarations] gets(s); ^~~~ In file included from /usr/include/c++/6/cstdio:42:0, from user.cpp:1: /usr/include/stdio.h:638:14: note: declared here extern char *gets (char *__s) __wur __attribute_deprecated__; ^~~~ user.cpp:21:15: warning: ‘char* gets(char*)’ is deprecated [-Wdeprecated-declarations] gets(s); ^ In file included from /usr/include/c++/6/cstdio:42:0, from user.cpp:1: /usr/include/stdio.h:638:14: note: declared here extern char *gets (char *__s) __wur __attribute_deprecated__; ^~~~ user.cpp:37:5: warning: this ‘for’ clause does not guard... [-Wmisleading-indentation] for(i=2;i<=n;i++) ^~~ user.cpp:54:9: note: ...this statement, but the latter is misleadingly indented as if it is guarded by the ‘for’ printf("%d %d\n",ma,cnt); ^~~~~~ user.cpp:15:36: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result] freopen("figuri2.in","r",stdin); ^ user.cpp:16:38: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result] freopen("figuri2.out","w",stdout); ^ user.cpp:18:21: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result] scanf("%d\n",&n); ^ user.cpp:21:16: warning: ignoring return value of ‘char* gets(char*)’, declared with attribute warn_unused_result [-Wunused-result] gets(s); ^ /tmp/ccLPpOq1.o: In function `main': user.cpp:(.text.startup+0x79): warning: the `gets' function is dangerous and should not be used.
Test Timp executie Memorie folosita Mesaj Punctaj/test
10ms892kbOK10
20ms996kbOK10
30ms1056kbOK10
40ms1116kbOK10
50ms1132kbOK10
60ms1160kbOK10
70ms1184kbOK10
80ms1224kbOK10
90ms1228kbOK10
100ms1232kbOK10
Punctaj total100

Ceva nu functioneaza?