Submission #980116

#TimeUsernameProblemLanguageResultExecution timeMemory
980116vjudge1Longest Trip (IOI23_longesttrip)C++17
Compilation error
0 ms0 KiB
#include <bits/stdc++.h> #define rep(a,b,c) for(int a=b; a<c; a++) #define repa(a,b) for(auto a:b) #define ll long long #define pll pair<ll, ll> #define pb push_back #define fi first #define se second using namespace std; int longest_trip(int N, int D){ vector<int> ans; rep(i,0,N) ans.pb(i); return ans; }

Compilation message (stderr)

longesttrip.cpp: In function 'int longest_trip(int, int)':
longesttrip.cpp:15:9: error: cannot convert 'std::vector<int>' to 'int' in return
   15 |  return ans;
      |         ^~~