template.hpp
- View this file on GitHub
- Last update: 2025-03-14 23:36:46+07:00
- Include:
#include "template.hpp"
- Link:
View error logs on GitHub Actions
Required by
data-structure/cartesian-tree.hpp
graph/twosat.hpp
verify/atcoder/abc193_f.cpp
verify/atcoder/abc259_g.cpp
verify/atcoder/abc347_g.cpp
verify/kattis/thekingofthenorth.cpp
verify/spoj/FASTFLOW.cpp
Verified with
verify/yosupo/convolution/bitwise_and_convolution.test.cpp
verify/yosupo/convolution/bitwise_or_convolution.test.cpp
verify/yosupo/convolution/bitwise_xor_convolution.test.cpp
verify/yosupo/convolution/gcd_convolution.test.cpp
verify/yosupo/convolution/lcm_convolution.test.cpp
verify/yosupo/convolution/min_plus_convolution_convex_arbitrary.test.cpp
verify/yosupo/data-structure/area_of_union_of_rectangles.test.cpp
verify/yosupo/data-structure/dynamic_sequence_range_affine_range_sum.test.cpp
verify/yosupo/data-structure/line_add_get_min.test.cpp
verify/yosupo/data-structure/persistent_queue.test.cpp
verify/yosupo/data-structure/point_add_range_sum.test.cpp
verify/yosupo/data-structure/point_set_range_composite.test.cpp
verify/yosupo/data-structure/point_set_tree_path_composite_sum.test.cpp
verify/yosupo/data-structure/point_set_tree_path_composite_sum_fixed_root.test.cpp
verify/yosupo/data-structure/range_affine_range_sum.test.cpp
verify/yosupo/data-structure/range_affine_range_sum_lct.test.cpp
verify/yosupo/data-structure/range_reverse_range_sum.test.cpp
verify/yosupo/data-structure/segment_add_get_min.test.cpp
verify/yosupo/data-structure/segment_add_get_min_online.test.cpp
verify/yosupo/data-structure/set_xor_min.test.cpp
verify/yosupo/data-structure/staticrmq.test.cpp
verify/yosupo/data-structure/unionfind.test.cpp
verify/yosupo/data-structure/vertex_add_path_sum.test.cpp
verify/yosupo/data-structure/vertex_add_subtree_sum.test.cpp
verify/yosupo/data-structure/vertex_set_path_composite.test.cpp
verify/yosupo/graph/scc.test.cpp
verify/yosupo/number-theory/sum_of_floor_of_linear.test.cpp
verify/yosupo/other/two_sat.test.cpp
verify/yosupo/string/enumerate_palindromes.test.cpp
verify/yosupo/string/number_of_substrings.test.cpp
verify/yosupo/string/number_of_substrings2.test.cpp
verify/yosupo/string/suffixarray.test.cpp
verify/yosupo/string/zalgorithm.test.cpp
verify/yosupo/tree/cartesian_tree.test.cpp
verify/yosupo/tree/jump_on_tree.test.cpp
verify/yosupo/tree/lca.test.cpp
Code
#pragma once
#include<bits/stdc++.h>
#include<ext/pb_ds/assoc_container.hpp>
#include<ext/pb_ds/tree_policy.hpp>
using namespace std;
using namespace __gnu_pbds;
using ll = long long;
using db = long double;
using vi = vector<int>;
using vl = vector<ll>;
using vd = vector<db>;
using pii = pair<int,int>;
using pll = pair<ll,ll>;
using pdd = pair<db,db>;
const int INF=INT_MAX/2;
const int MOD=998244353;
const int MOD2=1000000007;
const ll LINF=LLONG_MAX/2;
const db DINF=numeric_limits<db>::infinity();
const db EPS=1e-9;
const db PI=acos(db(-1));
template<class T>
using ordered_set = tree<T,null_type,less<T>,rb_tree_tag,tree_order_statistics_node_update>;
template<class T>
using ordered_multiset = tree<T,null_type,less_equal<T>,rb_tree_tag,tree_order_statistics_node_update>;
mt19937 rng(chrono::steady_clock::now().time_since_epoch().count());
mt19937_64 rng64(chrono::steady_clock::now().time_since_epoch().count());
#line 2 "template.hpp"
#include<bits/stdc++.h>
#include<ext/pb_ds/assoc_container.hpp>
#include<ext/pb_ds/tree_policy.hpp>
using namespace std;
using namespace __gnu_pbds;
using ll = long long;
using db = long double;
using vi = vector<int>;
using vl = vector<ll>;
using vd = vector<db>;
using pii = pair<int,int>;
using pll = pair<ll,ll>;
using pdd = pair<db,db>;
const int INF=INT_MAX/2;
const int MOD=998244353;
const int MOD2=1000000007;
const ll LINF=LLONG_MAX/2;
const db DINF=numeric_limits<db>::infinity();
const db EPS=1e-9;
const db PI=acos(db(-1));
template<class T>
using ordered_set = tree<T,null_type,less<T>,rb_tree_tag,tree_order_statistics_node_update>;
template<class T>
using ordered_multiset = tree<T,null_type,less_equal<T>,rb_tree_tag,tree_order_statistics_node_update>;
mt19937 rng(chrono::steady_clock::now().time_since_epoch().count());
mt19937_64 rng64(chrono::steady_clock::now().time_since_epoch().count());