Submission #871862

#TimeUsernameProblemLanguageResultExecution timeMemory
871862Mr_PhSpeedrun (RMI21_speedrun)C++14
Compilation error
0 ms0 KiB
#include "speedrun.h" #include <bits/stdc++.h> //#include "grader.cpp" using namespace std; int lol,st; void assignHints(int subtask, int n, int a[], int b[]) { setHintLen(n); for(int i=0;i<n-1;i++) { setHint(a[i],b[i],1); setHint(b[i],a[i],1); } lol=0; } void dfs(int node,int parent) { for(int i=1;i<=lol;i++) { if(i==parent)continue; if(getHint(node,i)) { goTo(i); dfs(i,node); } } if(node!=st) goTo(parent); } void speedrun(int subtask, int n, int start) { /* your solution here */ st=start; dfs(st,0); }

Compilation message (stderr)

speedrun.cpp: In function 'void dfs(int, int)':
speedrun.cpp:20:26: error: too many arguments to function 'bool getHint(int)'
   20 |         if(getHint(node,i))
      |                          ^
In file included from speedrun.cpp:1:
speedrun.h:11:6: note: declared here
   11 | bool getHint(int j);
      |      ^~~~~~~