QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#873389#9345. Artful PaintingsHuangHanShengCompile Error//C++142.9kb2025-01-26 12:54:172025-01-26 12:54:18

详细

answer.code: In function ‘int main()’:
answer.code:86:44: error: expected ‘;’ before ‘int’
   86 |         add_edge(n,0,0,0),add_edge(0,n,0,0)
      |                                            ^
      |                                            ;
   87 |         int l=0,r=n,ans=-1;  //????
      |         ~~~                                 
answer.code:88:15: error: ‘l’ was not declared in this scope
   88 |         while(l<=r) {
      |               ^
answer.code:88:18: error: ‘r’ was not declared in this scope
   88 |         while(l<=r) {
      |                  ^
answer.code:90:36: error: ‘ans’ was not declared in this scope; did you mean ‘abs’?
   90 |             if(check(mid)) r=mid-1,ans=mid;
      |                                    ^~~
      |                                    abs
answer.code:93:23: error: ‘ans’ was not declared in this scope; did you mean ‘abs’?
   93 |         printf("%d\n",ans);
      |                       ^~~
      |                       abs
answer.code:78:16: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   78 |     int t;scanf("%d",&t);
      |           ~~~~~^~~~~~~~~
answer.code:80:14: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   80 |         scanf("%d %d %d",&n,&m1,&m2);
      |         ~~~~~^~~~~~~~~~~~~~~~~~~~~~~
answer.code:81:37: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   81 |         for(int i=1;i<=m1;i++) scanf("%d %d %d",&a[i].l,&a[i].r,&a[i].w);
      |                                ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
answer.code:82:37: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   82 |         for(int i=1;i<=m2;i++) scanf("%d %d %d",&b[i].l,&b[i].r,&b[i].w);
      |                                ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~