-
Notifications
You must be signed in to change notification settings - Fork 1
/
Template.cpp
81 lines (79 loc) · 2.94 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
/**বিসমিল্লাহির রহমানির রহীম **/
#include<bits/stdc++.h>
#define pi acos(-1.0)
#define eps 1e-9
#define ff first
#define ss second
#define nl '\n'
#define sp ' '
#define CLR(a) memset(a,0,sizeof(a))
#define SET(a) memset(a,-1,sizeof(a))
#define all(x) x.begin(),x.end()
#define allr(x) x.rbegin(),x.rend()
#define sz(x) (int)(x).size()
#define Fast_Read ios_base::sync_with_stdio(false); cin.tie(nullptr); cout.tie(nullptr);
#define Precision(x) cout.setf(ios::fixed); cout.precision(x);
using namespace std;
int dx[]={0,0,1,-1,-1,-1,1,1};
int dy[]={1,-1,0,0,-1,1,1,-1};
typedef long long ll;
typedef long double ld;
typedef pair<int,int> pii;
template < class T> inline T bitOn(T n,T pos){return n |((T)1<<pos);}
template < class T> inline T bitOff(T n,T pos){return n & ~((T)1<<pos);}
template < class T> inline T isOn(T n,T pos){return (bool)(n & ((T)1<<pos));}
template < class T> inline T lcm(T a, T b){return (a/__gcd(a, b)) * b;}
inline int nxt(){int aaa;scanf("%d",&aaa);return aaa;}
inline ll lxt(){ll aaa;scanf("%lld",&aaa);return aaa;}
inline double dxt(){double aaa;scanf("%lf",&aaa);return aaa;}
template <class T> inline T bigmod(T p,T e,T m){
T ret = 1;
for(; e > 0; e >>= 1){
if(e & 1) ret = (ret * p) % m;p = (p * p) % m;
}
return (T)ret;
}
#ifdef obaydullah
#define debug(...) __f(#__VA_ARGS__, __VA_ARGS__)
template < typename Arg1 >
void __f(const char* name, Arg1&& arg1){
cerr << name << " is " << arg1 << std::endl;
}
template < typename Arg1, typename... Args>
void __f(const char* names, Arg1&& arg1, Args&&... args){
const char* comma = strchr(names+1, ',');
cerr.write(names, comma - names) << " is " << arg1 <<" | ";
__f(comma+1, args...);
}
#else
#define debug(...)
#endif
template<class T>
istream& operator>>(istream& is, vector<T>& input){
for(T& in:input) is >> in; return is;
}
template<class T>
ostream& operator<<(ostream& os, const vector<T> &input){
bool isFirst=true;for(const T& out:input){if(isFirst){os<<out;isFirst=false;}else os<<" "<<out;}return os;
}
///******************************************START******************************************
void solve(){
}
int main(){
Fast_Read
Precision(10)
#ifdef obaydullah
double start_time = clock();
///freopen ("output.txt","w",stdout);
///freopen ("input.txt","r",stdin);
#endif
int tc=1;
while(tc--){
solve();
}
#ifdef obaydullah
double end_time = clock();
cerr<<"Time = "<<fixed<<setprecision(10)<<(end_time - start_time) / CLOCKS_PER_SEC<<'\n';
#endif
return 0;
}