Mã chấm: 269275
Main.cc: In function ‘int main()’: Main.cc:10:19: warning: ‘char* gets(char*)’ is deprecated [-Wdeprecated-declarations] gets("%s",s[n]); ^ In file included from /usr/include/stdio.h:862:0, from Main.cc:1: /usr/include/x86_64-linux-gnu/bits/stdio2.h:232:1: note: declared here gets (char *__str) ^~~~ Main.cc:10:19: warning: ISO C++ forbids converting a string constant to ‘char*’ [-Wwrite-strings] gets("%s",s[n]); ^ Main.cc:10:19: error: too many arguments to function ‘char* gets(char*)’ In file included from /usr/include/stdio.h:862:0, from Main.cc:1: /usr/include/x86_64-linux-gnu/bits/stdio2.h:232:1: note: declared here gets (char *__str) ^~~~ Main.cc:9:10: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result] scanf("%d",&n); ~~~~~^~~~~~~~~ Main.cc:10:9: warning: ignoring return value of ‘char* gets(char*)’, declared with attribute warn_unused_result [-Wunused-result] gets("%s",s[n]); ~~~~^~~~~~~~~~~