Submission #479886

#TimeUsernameProblemLanguageResultExecution timeMemory
479886glomeConnecting Supertrees (IOI20_supertrees)C++17
0 / 100
1 ms292 KiB
#include "supertrees.h" #include <vector> #include<bits/stdc++.h> using namespace std; int construct(std::vector<std::vector<int>> p) { bool ok = 1; for (int i = 0; i<p.size(); i++) { for (int j = 0; j<p.size(); j++) { ok &= p[i][j]; } } if(ok) { for (int i = 0; i<p.size(); i++) { p[i][i] = 0; } build(p); return 1; } }

Compilation message (stderr)

supertrees.cpp: In function 'int construct(std::vector<std::vector<int> >)':
supertrees.cpp:9:19: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<std::vector<int> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
    9 |  for (int i = 0; i<p.size(); i++) {
      |                  ~^~~~~~~~~
supertrees.cpp:10:20: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<std::vector<int> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   10 |   for (int j = 0; j<p.size(); j++) {
      |                   ~^~~~~~~~~
supertrees.cpp:15:20: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<std::vector<int> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   15 |   for (int i = 0; i<p.size(); i++) {
      |                   ~^~~~~~~~~
supertrees.cpp:21:1: warning: control reaches end of non-void function [-Wreturn-type]
   21 | }
      | ^
#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...