Borderou de evaluare (job #3196959)
Utilizator | Data | 25 ianuarie 2024 03:00:48 | |
---|---|---|---|
Problema | Arbore partial de cost minim | Status | done |
Runda | Arhiva educationala | Compilator | cpp-64 | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
main.cpp: In function 'void make_set(int)':
main.cpp:22:5: error: reference to 'rank' is ambiguous
22 | rank[v] = 0;
| ^~~~
In file included from /usr/include/c++/12.2.1/bits/stl_pair.h:60,
from /usr/include/c++/12.2.1/bits/stl_algobase.h:64,
from /usr/include/c++/12.2.1/bits/specfun.h:45,
from /usr/include/c++/12.2.1/cmath:1935,
from /usr/include/c++/12.2.1/x86_64-pc-linux-gnu/bits/stdc++.h:41,
from main.cpp:1:
/usr/include/c++/12.2.1/type_traits:1394:12: note: candidates are: 'template<class> struct std::rank'
1394 | struct rank
| ^~~~
main.cpp:12:21: note: 'std::vector<int> rank'
12 | vector<int> parent, rank;
| ^~~~
main.cpp: In function 'void union_sets(int, int)':
main.cpp:29:13: error: reference to 'rank' is ambiguous
29 | if (rank[a] < rank[b])
| ^~~~
/usr/include/c++/12.2.1/type_traits:1394:12: note: candidates are: 'template<class> struct std::rank'
1394 | struct rank
| ^~~~
main.cpp:12:21: note: 'std::vector<int> rank'
12 | vector<int> parent, rank;
| ^~~~
main.cpp:29:23: error: reference to 'rank' is ambiguous
29 | if (rank[a] < rank[b])
| ^~~~
/usr/include/c++/12.2.1/type_traits:1394:12: note: candidates are: 'template<class> struct std::rank'
1394 | struct rank
| ^~~~
main.cpp:12:21: note: 'std::vector<int> rank'
12 | vector<int> parent, rank;
| ^~~~
main.cpp:32:13: error: reference to 'rank' is ambiguous
32 | if (rank[a] == rank[b])
| ^~~~
/usr/include/c++/12.2.1/type_traits:1394:12: note: candidates are: 'template<class> struct std::rank'
1394 | struct rank
| ^~~~
main.cpp:12:21: note: 'std::vector<int> rank'
12 | vector<int> parent, rank;
| ^~~~
main.cpp:32:24: error: reference to 'rank' is ambiguous
32 | if (rank[a] == rank[b])
| ^~~~
/usr/include/c++/12.2.1/type_traits:1394:12: note: candidates are: 'template<class> struct std::rank'
1394 | struct rank
| ^~~~
Non zero exit status: 1
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !