Submission #745392

#TimeUTC-0UsernameProblemLanguageResultExecution timeMemory
7453922023-05-20 00:55:26arthur_nascimentoReconstruction Project (JOI22_reconstruction)C++14
3 / 100
5044 ms19008 KiB
#include <bits/stdc++.h>
using namespace std;
#define maxn 1010
#define maxE 100100
#define pb push_back
#define debug
#define pii pair<int,int>
#define ll long long
#define mod 998244353
#define inf (1<<30)
struct edge {
int a,b,w;
bool operator < (edge comp){
return w < comp.w;
}
edge(int a=0,int b=0,int w=0) : a(a), b(b), w(w) {}
}
E[maxE];
 
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Compilation message (stderr)

reconstruction.cpp: In function 'long long int get(std::vector<int>, std::vector<int>, int)':
reconstruction.cpp:76:8: warning: left operand of comma operator has no effect [-Wunused-value]
   76 |  debug("esq is %d len %d, dir is %d len %d\n",ini[0],len[0],ini[1],len[1]);
      |        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
reconstruction.cpp:96:9: warning: left operand of comma operator has no effect [-Wunused-value]
   96 |   debug("proc (%d,%d)\n",a,b);
      |         ^~~~~~~~~~~~~~~~
reconstruction.cpp:96:28: warning: right operand of comma operator has no effect [-Wunused-value]
   96 |   debug("proc (%d,%d)\n",a,b);
      |                            ^
reconstruction.cpp:103:9: warning: left operand of comma operator has no effect [-Wunused-value]
  103 |   debug("added (%d,%d), w = %d\n",a,b,w);
      |         ^~~~~~~~~~~~~~~~~~~~~~~~~
reconstruction.cpp:103:37: warning: right operand of comma operator has no effect [-Wunused-value]
  103 |   debug("added (%d,%d), w = %d\n",a,b,w);
      |                                     ^
reconstruction.cpp:103:39: warning: right operand of comma operator has no effect [-Wunused-value]
  103 |   debug("added (%d,%d), w = %d\n",a,b,w);
      |                                       ^
reconstruction.cpp: At global scope:
reconstruction.cpp:116:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
  116 | main(){
      | ^~~~
reconstruction.cpp: In function 'int main()':
reconstruction.cpp:118:7: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
  118 |  scanf("%d%d",&n,&m);
      |  ~~~~~^~~~~~~~~~~~~~
reconstruction.cpp:121:8: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
  121 |   scanf("%d%d%d",&E[i].a,&E[i].b,&E[i].w), E[i].a--, E[i].b--;
      |   ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
reconstruction.cpp:139:7: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
  139 |  scanf("%d",&q);
      |  ~~~~~^~~~~~~~~
reconstruction.cpp:144:8: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
  144 |   scanf("%d",&X);
      |   ~~~~~^~~~~~~~~
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...