Kamuoliukų automatas (BOI 2013)
- [1] 2020-02-22 18:57 (0)
- [2] 2020-02-22 19:00 (29.4)
- [3] 2020-02-22 23:15 (47.1)
- [4] 2020-02-23 09:45 (47.1)
- [5] 2020-02-23 13:25 (100)
Taškai: 0
Compile: FAIL
kamuoliuku_automatas.cpp:28:5: error: ‘int index’ redeclared as different kind of symbol int index = 1; ^ In file included from /usr/include/c++/5/cstring:42:0, from /usr/include/x86_64-linux-gnu/c++/5/bits/stdc++.h:48, from kamuoliuku_automatas.cpp:1: /usr/include/string.h:477:1: note: previous declaration ‘const char* index(const char*, int)’ index (const char *__s, int __c) __THROW ^ kamuoliuku_automatas.cpp: In function ‘void dfs2(int)’: kamuoliuku_automatas.cpp:115:25: error: no matching function for call to ‘std::priority_queue<std::pair<int, int>, std::vector<std::pair<int, int> >, std::greater<std::pair<int, int> > >::push(<brace-enclosed initializer list>)’ adds.push({index, x}); ^ In file included from /usr/include/c++/5/queue:64:0, from /usr/include/x86_64-linux-gnu/c++/5/bits/stdc++.h:85, from kamuoliuku_automatas.cpp:1: /usr/include/c++/5/bits/stl_queue.h:499:7: note: candidate: void std::priority_queue<_Tp, _Sequence, _Compare>::push(const value_type&) [with _Tp = std::pair<int, int>; _Sequence = std::vector<std::pair<int, int> >; _Compare = std::greater<std::pair<int, int> >; std::priority_queue<_Tp, _Sequence, _Compare>::value_type = std::pair<int, int>] push(const value_type& __x) ^ /usr/include/c++/5/bits/stl_queue.h:499:7: note: no known conversion for argument 1 from ‘<brace-enclosed initializer list>’ to ‘const value_type& {aka const std::pair<int, int>&}’ /usr/include/c++/5/bits/stl_queue.h:507:7: note: candidate: void std::priority_queue<_Tp, _Sequence, _Compare>::push(std::priority_queue<_Tp, _Sequence, _Compare>::value_type&&) [with _Tp = std::pair<int, int>; _Sequence = std::vector<std::pair<int, int> >; _Compare = std::greater<std::pair<int, int> >; std::priority_queue<_Tp, _Sequence, _Compare>::value_type = std::pair<int, int>] push(value_type&& __x) ^ /usr/include/c++/5/bits/stl_queue.h:507:7: note: no known conversion for argument 1 from ‘<brace-enclosed initializer list>’ to ‘std::priority_queue<std::pair<int, int>, std::vector<std::pair<int, int> >, std::greater<std::pair<int, int> > >::value_type&& {aka std::pair<int, int>&&}’ kamuoliuku_automatas.cpp:116:12: error: cannot resolve overloaded function ‘index’ based on conversion to type ‘int’ pos[x] = index; ^ kamuoliuku_automatas.cpp:117:10: error: no post-increment operator for type index++; ^
nr. | result | time | message |
---|