-
Notifications
You must be signed in to change notification settings - Fork 0
/
__template.cpp
92 lines (72 loc) · 1.57 KB
/
__template.cpp
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
/**
* author: abhishekvtangod
**/
// #undef _GLIBCXX_DEBUG
// #undef _ABHI
#include<bits/stdc++.h>
using namespace std;
#define mod 1000000007
#define gcd(a,b) __gcd(a,b)
#define lcm(a,b) a/gcd(a,b)*b // no overflow
#define bits(x) __builtin_popcountll(x)
#define endl "\n"
#define IOS ios::sync_with_stdio(0); cin.tie(0); cout.tie(0);
typedef long long int ll;
string to_string(const string &s){
return "{" + s + "}";
}
string to_string(const char &c){
string s = "";
s += c;
return s;
}
template <typename A, typename B>
string to_string(const pair<A, B> &p){
return "(" + to_string(p.first) + ", " + to_string(p.second) + ")";
}
template <typename A, typename B, typename C>
string to_string(const tuple<A, B, C> &t){
return "(" + to_string(get<0>(t)) + ", " + to_string(get<1>(t)) + ", " + to_string(get<2>(t)) + ")";
}
template <typename A>
string to_string(A v){
string res = "{";
bool f = 0;
for(const auto &u: v){
if(f){
res += ", ";
}
f = 1;
res += to_string(u);
}
res += "}";
return res;
}
void cus_debug() { cerr << "]" << endl; }
template <typename Head, typename... Tail>
void cus_debug(Head H, Tail... T) {
cerr << to_string(H) << ", ";
cus_debug(T...);
}
#ifdef _GLIBCXX_DEBUG
#define debug(x...) cerr << "[" << #x << "]:[", cus_debug(x)
#else
#define debug(...) 42
#endif
// start of CP 2.0
void solve(){
}
int main()
{
IOS;
#ifdef _ABHI
freopen("/home/abhi/Documents/input.txt", "r", stdin);
freopen("/home/abhi/Documents/output.txt", "w", stdout);
#endif
ll t=1;
// cin>>t;
while(t--){
solve();
}
return 0;
}