Submission #740000

#TimeUsernameProblemLanguageResultExecution timeMemory
740000fractlpacaQuality Of Living (IOI10_quality)C++17
Compilation error
0 ms0 KiB
#include <stdio.h> #include <stdlib.h> #include "quality.h" static int R,C,H,W,Q[3001][3001],i,j,ans; int main(){ scanf("%d%d%d%d",&R,&C,&H,&W); for (i=0;i<R;i++) for (j=0;j<C;j++) scanf("%d",&Q[i][j]); ans = rectangle(R,C,H,W,Q); printf("%d\n",ans); return 0; }

Compilation message (stderr)

quality.cpp: In function 'int main()':
quality.cpp:7:9: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
    7 |    scanf("%d%d%d%d",&R,&C,&H,&W);
      |    ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
quality.cpp:8:45: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
    8 |    for (i=0;i<R;i++) for (j=0;j<C;j++) scanf("%d",&Q[i][j]);
      |                                        ~~~~~^~~~~~~~~~~~~~~
/usr/bin/ld: /tmp/cca7KPoL.o: in function `main':
grader.cpp:(.text.startup+0x0): multiple definition of `main'; /tmp/ccoFf5RL.o:quality.cpp:(.text.startup+0x0): first defined here
/usr/bin/ld: /tmp/ccoFf5RL.o: in function `main':
quality.cpp:(.text.startup+0xd4): undefined reference to `rectangle(int, int, int, int, int (*) [3001])'
/usr/bin/ld: /tmp/cca7KPoL.o: in function `main':
grader.cpp:(.text.startup+0xe9): undefined reference to `rectangle(int, int, int, int, int (*) [3001])'
collect2: error: ld returned 1 exit status