QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#569983#5148. Tree DistanceaaaaaCompile Error//C++202.4kb2024-09-17 13:04:382024-09-17 13:04:39

詳細信息

answer.code: In function ‘void dfs(long long int)’:
answer.code:59:28: error: no ‘operator--(int)’ declared for postfix ‘--’ [-fpermissive]
   59 |                         pos--;
      |                         ~~~^~
answer.code: In function ‘int main()’:
answer.code:96:17: warning: format ‘%d’ expects argument of type ‘int*’, but argument 2 has type ‘long long int*’ [-Wformat=]
   96 |         scanf("%d",&n);
      |                ~^  ~~
      |                 |  |
      |                 |  long long int*
      |                 int*
      |                %lld
answer.code:98:25: warning: format ‘%d’ expects argument of type ‘int*’, but argument 2 has type ‘long long int*’ [-Wformat=]
   98 |                 scanf("%d%d%d",&a,&b,&c);
      |                        ~^      ~~
      |                         |      |
      |                         int*   long long int*
      |                        %lld
answer.code:98:27: warning: format ‘%d’ expects argument of type ‘int*’, but argument 3 has type ‘long long int*’ [-Wformat=]
   98 |                 scanf("%d%d%d",&a,&b,&c);
      |                          ~^       ~~
      |                           |       |
      |                           int*    long long int*
      |                          %lld
answer.code:98:29: warning: format ‘%d’ expects argument of type ‘int*’, but argument 4 has type ‘long long int*’ [-Wformat=]
   98 |                 scanf("%d%d%d",&a,&b,&c);
      |                            ~^        ~~
      |                             |        |
      |                             int*     long long int*
      |                            %lld
answer.code:113:17: warning: format ‘%d’ expects argument of type ‘int*’, but argument 2 has type ‘long long int*’ [-Wformat=]
  113 |         scanf("%d",&q);
      |                ~^  ~~
      |                 |  |
      |                 |  long long int*
      |                 int*
      |                %lld
answer.code:115:25: warning: format ‘%d’ expects argument of type ‘int*’, but argument 2 has type ‘long long int*’ [-Wformat=]
  115 |                 scanf("%d%d",&a,&b);
      |                        ~^    ~~
      |                         |    |
      |                         int* long long int*
      |                        %lld
answer.code:115:27: warning: format ‘%d’ expects argument of type ‘int*’, but argument 3 has type ‘long long int*’ [-Wformat=]
  115 |                 scanf("%d%d",&a,&b);
      |                          ~^     ~~
      |                           |     |
      |                           int*  long long int*
      |                          %lld
answer.code:133:17: error: ‘prllf’ was not declared in this scope
  133 |                 prllf("%lld\n",ans[i]);
      |                 ^~~~~
answer.code:96:14: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   96 |         scanf("%d",&n);
      |         ~~~~~^~~~~~~~~
answer.code:98:22: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   98 |                 scanf("%d%d%d",&a,&b,&c);
      |                 ~~~~~^~~~~~~~~~~~~~~~~~~
answer.code:113:14: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
  113 |         scanf("%d",&q);
      |         ~~~~~^~~~~~~~~
answer.code:115:22: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
  115 |                 scanf("%d%d",&a,&b);
      |                 ~~~~~^~~~~~~~~~~~~~