Submission #554613

#TimeUTC-0UsernameProblemLanguageResultExecution timeMemory
5546132022-04-28 23:50:05Zhora_004Road Closures (APIO21_roads)C++17
Compilation error
0 ms0 KiB
#include "roads.h"
#include <iostream>
#include <cmath>
#include <algorithm>
#include <vector>
#include <set>
#include <unordered_set>
#include <queue>
#include <deque>
#include <string>
#include <sstream>
#include <iomanip>
#include <map>
#include <unordered_map>
#include <stack>
#include <cstdio>
#include <climits>
#include <tuple>
#include <ctime>
#include <cstring>
#include <numeric>
#include <functional>
#include <chrono>
#include <cassert>
#include <bitset>
#include <fstream>
#define sz(a) ((int)((a).size()))
using ll = long long;
using namespace std;
const int inf = 1e9;
 
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Compilation message (stderr)

roads.cpp: In function 'void dfs(int, int, int)':
roads.cpp:87:24: warning: unused variable 'len' [-Wunused-variable]
   87 |    int v = edge.first, len = edge.second;
      |                        ^~~
roads.cpp: In function 'std::vector<long long int> minimum_closure_costs(int, std::vector<int>, std::vector<int>, std::vector<int>)':
roads.cpp:152:30: error: no matching function for call to 'iota(std::vector<int>::iterator, std::vector<int>::iterator)'
  152 |   iota(vec.begin(), vec.end());
      |                              ^
In file included from /usr/include/c++/10/numeric:62,
                 from roads.cpp:21:
/usr/include/c++/10/bits/stl_numeric.h:88:5: note: candidate: 'template<class _ForwardIterator, class _Tp> void std::iota(_ForwardIterator, _ForwardIterator, _Tp)'
   88 |     iota(_ForwardIterator __first, _ForwardIterator __last, _Tp __value)
      |     ^~~~
/usr/include/c++/10/bits/stl_numeric.h:88:5: note:   template argument deduction/substitution failed:
roads.cpp:152:30: note:   candidate expects 3 arguments, 2 provided
  152 |   iota(vec.begin(), vec.end());
      |                              ^