# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
170212 | 2019-12-24 08:49:44 | theboatman | Simple game (IZhO17_game) | C++17 | Compilation error | 0 ms | 0 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
#include <bits/stdc++.h>
#pragma GCC optimize("-O3")
#pragma GCC optimize("Ofast")
#pragma GCC optimize("unroll-loops")
#pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native")
#include<ext/pb_ds/tree_policy.hpp>
#include<ext/pb_ds/assoc_container.hpp>
#define y1 theboatman
#define make_struct(args...) {args}
using namespace std;
using namespace __gnu_pbds;
typedef long long ll;
template <typename T> using ordset = tree <T, null_type, less<T>, rb_tree_tag, tree_order_statistics_node_update>;
const long long ll(INF) = 1e18 + 10;
const int int(inf) = 1e9 + 10;
const int N = int(1e6) + 10;
struct Tree {
int n, timer;
vector <ordset <pair <int, int> > > t;
void init(int _n) {
n = _n;
timer = 0;
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
Compilation message (stderr)
game.cpp:20:23: error: 'const long long int ll' redeclared as different kind of symbol const long long ll(INF) = 1e18 + 10; ^ game.cpp:17:19: note: previous declaration 'typedef long long int ll' typedef long long ll; ^~ game.cpp:20:20: error: 'INF' was not declared in this scope const long long ll(INF) = 1e18 + 10; ^~~ game.cpp:20:20: note: suggested alternative: 'SING' const long long ll(INF) = 1e18 + 10; ^~~ SING game.cpp:21:18: error: two or more data types in declaration of 'inf' const int int(inf) = 1e9 + 10; ^ game.cpp: In member function 'void Tree::del(int, int)': game.cpp:43:48: error: 'inf' was not declared in this scope t[i].erase(t[i].lower_bound({val, -inf})); ^~~ game.cpp:43:48: note: suggested alternative: 'ynf' t[i].erase(t[i].lower_bound({val, -inf})); ^~~ ynf game.cpp:43:52: error: no matching function for call to '__gnu_pbds::tree<std::pair<int, int>, __gnu_pbds::null_type, std::less<std::pair<int, int> >, __gnu_pbds::rb_tree_tag, __gnu_pbds::tree_order_statistics_node_update, std::allocator<char> >::lower_bound(<brace-enclosed initializer list>)' t[i].erase(t[i].lower_bound({val, -inf})); ^ In file included from /usr/include/c++/7/ext/pb_ds/detail/container_base_dispatch.hpp:84:0, from /usr/include/c++/7/ext/pb_ds/assoc_container.hpp:48, from game.cpp:9: /usr/include/c++/7/ext/pb_ds/detail/bin_search_tree_/find_fn_imps.hpp:62:1: note: candidate: __gnu_pbds::detail::bin_search_tree_set<Key, Mapped, Cmp_Fn, Node_And_It_Traits, _Alloc>::point_iterator __gnu_pbds::detail::bin_search_tree_set<Key, Mapped, Cmp_Fn, Node_And_It_Traits, _Alloc>::lower_bound(__gnu_pbds::detail::bin_search_tree_set<Key, Mapped, Cmp_Fn, Node_And_It_Traits, _Alloc>::key_const_reference) [with Key = std::pair<int, int>; Mapped = __gnu_pbds::null_type; Cmp_Fn = std::less<std::pair<int, int> >; Node_And_It_Traits = __gnu_pbds::detail::tree_traits<std::pair<int, int>, __gnu_pbds::null_type, std::less<std::pair<int, int> >, __gnu_pbds::tree_order_statistics_node_update, __gnu_pbds::rb_tree_tag, std::allocator<char> >; _Alloc = std::allocator<char>; __gnu_pbds::detail::bin_search_tree_set<Key, Mapped, Cmp_Fn, Node_And_It_Traits, _Alloc>::point_iterator = __gnu_pbds::detail::bin_search_tree_const_it_<__gnu_pbds::detail::rb_tree_node_<std::pair<int, int>, long unsigned int, std::allocator<char> >*, std::pair<int, int>, std::pair<int, int>*, const std::pair<int, int>*, std::pair<int, int>&, const std::pair<int, int>&, true, std::allocator<char> >; __gnu_pbds::detail::bin_search_tree_set<Key, Mapped, Cmp_Fn, Node_And_It_Traits, _Alloc>::key_const_reference = const std::pair<int, int>&] PB_DS_CLASS_C_DEC:: ^ /usr/include/c++/7/ext/pb_ds/detail/bin_search_tree_/find_fn_imps.hpp:62:1: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to '__gnu_pbds::detail::bin_search_tree_set<std::pair<int, int>, __gnu_pbds::null_type, std::less<std::pair<int, int> >, __gnu_pbds::detail::tree_traits<std::pair<int, int>, __gnu_pbds::null_type, std::less<std::pair<int, int> >, __gnu_pbds::tree_order_statistics_node_update, __gnu_pbds::rb_tree_tag, std::allocator<char> >, std::allocator<char> >::key_const_reference {aka const std::pair<int, int>&}' /usr/include/c++/7/ext/pb_ds/detail/bin_search_tree_/find_fn_imps.hpp:43:1: note: candidate: __gnu_pbds::detail::bin_search_tree_set<Key, Mapped, Cmp_Fn, Node_And_It_Traits, _Alloc>::point_const_iterator __gnu_pbds::detail::bin_search_tree_set<Key, Mapped, Cmp_Fn, Node_And_It_Traits, _Alloc>::lower_bound(__gnu_pbds::detail::bin_search_tree_set<Key, Mapped, Cmp_Fn, Node_And_It_Traits, _Alloc>::key_const_reference) const [with Key = std::pair<int, int>; Mapped = __gnu_pbds::null_type; Cmp_Fn = std::less<std::pair<int, int> >; Node_And_It_Traits = __gnu_pbds::detail::tree_traits<std::pair<int, int>, __gnu_pbds::null_type, std::less<std::pair<int, int> >, __gnu_pbds::tree_order_statistics_node_update, __gnu_pbds::rb_tree_tag, std::allocator<char> >; _Alloc = std::allocator<char>; __gnu_pbds::detail::bin_search_tree_set<Key, Mapped, Cmp_Fn, Node_And_It_Traits, _Alloc>::point_const_iterator = __gnu_pbds::detail::bin_search_tree_const_it_<__gnu_pbds::detail::rb_tree_node_<std::pair<int, int>, long unsigned int, std::allocator<char> >*, std::pair<int, int>, std::pair<int, int>*, const std::pair<int, int>*, std::pair<int, int>&, const std::pair<int, int>&, true, std::allocator<char> >; __gnu_pbds::detail::bin_search_tree_set<Key, Mapped, Cmp_Fn, Node_And_It_Traits, _Alloc>::key_const_reference = const std::pair<int, int>&] PB_DS_CLASS_C_DEC:: ^ /usr/include/c++/7/ext/pb_ds/detail/bin_search_tree_/find_fn_imps.hpp:43:1: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to '__gnu_pbds::detail::bin_search_tree_set<std::pair<int, int>, __gnu_pbds::null_type, std::less<std::pair<int, int> >, __gnu_pbds::detail::tree_traits<std::pair<int, int>, __gnu_pbds::null_type, std::less<std::pair<int, int> >, __gnu_pbds::tree_order_statistics_node_update, __gnu_pbds::rb_tree_tag, std::allocator<char> >, std::allocator<char> >::key_const_reference {aka const std::pair<int, int>&}' game.cpp: In member function 'int Tree::get(int, int)': game.cpp:50:61: error: 'inf' was not declared in this scope ans += t[i].size() - t[i].order_of_key({r + 1, -inf}); ^~~ game.cpp:50:61: note: suggested alternative: 'ynf' ans += t[i].size() - t[i].order_of_key({r + 1, -inf}); ^~~ ynf game.cpp:50:65: error: no matching function for call to '__gnu_pbds::tree<std::pair<int, int>, __gnu_pbds::null_type, std::less<std::pair<int, int> >, __gnu_pbds::rb_tree_tag, __gnu_pbds::tree_order_statistics_node_update, std::allocator<char> >::order_of_key(<brace-enclosed initializer list>)' ans += t[i].size() - t[i].order_of_key({r + 1, -inf}); ^ In file included from game.cpp:8:0: /usr/include/c++/7/ext/pb_ds/detail/tree_policy/order_statistics_imp.hpp:76:1: note: candidate: __gnu_pbds::tree_order_statistics_node_update<Node_CItr, Node_Itr, Cmp_Fn, _Alloc>::size_type __gnu_pbds::tree_order_statistics_node_update<Node_CItr, Node_Itr, Cmp_Fn, _Alloc>::order_of_key(__gnu_pbds::tree_order_statistics_node_update<Node_CItr, Node_Itr, Cmp_Fn, _Alloc>::key_const_reference) const [with Node_CItr = __gnu_pbds::detail::bin_search_tree_const_node_it_<__gnu_pbds::detail::rb_tree_node_<std::pair<int, int>, long unsigned int, std::allocator<char> >, __gnu_pbds::detail::bin_search_tree_const_it_<__gnu_pbds::detail::rb_tree_node_<std::pair<int, int>, long unsigned int, std::allocator<char> >*, std::pair<int, int>, std::pair<int, int>*, const std::pair<int, int>*, std::pair<int, int>&, const std::pair<int, int>&, true, std::allocator<char> >, __gnu_pbds::detail::bin_search_tree_const_it_<__gnu_pbds::detail::rb_tree_node_<std::pair<int, int>, long unsigned int, std::allocator<char> >*, std::pair<int, int>, std::pair<int, int>*, const std::pair<int, int>*, std::pair<int, int>&, const std::pair<int, int>&, true, std::allocator<char> >, std::allocator<char> >; Node_Itr = __gnu_pbds::detail::bin_search_tree_const_node_it_<__gnu_pbds::detail::rb_tree_node_<std::pair<int, int>, long unsigned int, std::allocator<char> >, __gnu_pbds::detail::bin_search_tree_const_it_<__gnu_pbds::detail::rb_tree_node_<std::pair<int, int>, long unsigned int, std::allocator<char> >*, std::pair<int, int>, std::pair<int, int>*, const std::pair<int, int>*, std::pair<int, int>&, const std::pair<int, int>&, true, std::allocator<char> >, __gnu_pbds::detail::bin_search_tree_const_it_<__gnu_pbds::detail::rb_tree_node_<std::pair<int, int>, long unsigned int, std::allocator<char> >*, std::pair<int, int>, std::pair<int, int>*, const std::pair<int, int>*, std::pair<int, int>&, const std::pair<int, int>&, true, std::allocator<char> >, std::allocator<char> >; Cmp_Fn = std::less<std::pair<int, int> >; _Alloc = std::allocator<char>; __gnu_pbds::tree_order_statistics_node_update<Node_CItr, Node_Itr, Cmp_Fn, _Alloc>::size_type = long unsigned int; __gnu_pbds::tree_order_statistics_node_update<Node_CItr, Node_Itr, Cmp_Fn, _Alloc>::key_const_reference = const std::pair<int, int>&] PB_DS_CLASS_C_DEC:: ^ /usr/include/c++/7/ext/pb_ds/detail/tree_policy/order_statistics_imp.hpp:76:1: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to '__gnu_pbds::tree_order_statistics_node_update<__gnu_pbds::detail::bin_search_tree_const_node_it_<__gnu_pbds::detail::rb_tree_node_<std::pair<int, int>, long unsigned int, std::allocator<char> >, __gnu_pbds::detail::bin_search_tree_const_it_<__gnu_pbds::detail::rb_tree_node_<std::pair<int, int>, long unsigned int, std::allocator<char> >*, std::pair<int, int>, std::pair<int, int>*, const std::pair<int, int>*, std::pair<int, int>&, const std::pair<int, int>&, true, std::allocator<char> >, __gnu_pbds::detail::bin_search_tree_const_it_<__gnu_pbds::detail::rb_tree_node_<std::pair<int, int>, long unsigned int, std::allocator<char> >*, std::pair<int, int>, std::pair<int, int>*, const std::pair<int, int>*, std::pair<int, int>&, const std::pair<int, int>&, true, std::allocator<char> >, std::allocator<char> >, __gnu_pbds::detail::bin_search_tree_const_node_it_<__gnu_pbds::detail::rb_tree_node_<std::pair<int, int>, long unsigned int, std::allocator<char> >, __gnu_pbds::detail::bin_search_tree_const_it_<__gnu_pbds::detail::rb_tree_node_<std::pair<int, int>, long unsigned int, std::allocator<char> >*, std::pair<int, int>, std::pair<int, int>*, const std::pair<int, int>*, std::pair<int, int>&, const std::pair<int, int>&, true, std::allocator<char> >, __gnu_pbds::detail::bin_search_tree_const_it_<__gnu_pbds::detail::rb_tree_node_<std::pair<int, int>, long unsigned int, std::allocator<char> >*, std::pair<int, int>, std::pair<int, int>*, const std::pair<int, int>*, std::pair<int, int>&, const std::pair<int, int>&, true, std::allocator<char> >, std::allocator<char> >, std::less<std::pair<int, int> >, std::allocator<char> >::key_const_reference {aka const std::pair<int, int>&}'