-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathkickstart.sublime-snippet
70 lines (58 loc) · 1.92 KB
/
kickstart.sublime-snippet
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
<snippet>
<content><![CDATA[
#include<bits/stdc++.h>
using namespace std;
#define ll long long
#define infi INT_MAX
const long long mod = 1000000007;
#define spc " "
#define nline "\n"
#define pii pair<int,int>
#define all(a) a.begin(), a.end()
#define print(a) cout << (a) << nline;
#define print2(a,b) cout << (a) << " " << (b) << nline;
#define logarr(arr,a,b) for(int z=(a);z<=(b);z++) cout<<(arr[z])<<" ";cout<<endl;
#define printarr(arr,n) logarr(arr,0,n-1)
#define printmat(arr,r,c) for(int i=(0);i<(r);++i){logarr(arr[i],0,c-1)}
#define rep(i,_srt,_end) for(int i=(_srt); i < (_end); ++i)
#ifndef ONLINE_JUDGE
#define bug(...) __f (#__VA_ARGS__, __VA_ARGS__)
#else
#define bug(...) ;
#endif
template <typename Arg1>
void __f (const char* name, Arg1&& arg1) {cout << name << " : " << arg1 << endl; }
template <typename Arg1, typename... Args>
void __f (const char* names, Arg1&& arg1, Args&&... args) {
const char* comma = strchr (names + 1, ',');
cout.write(names, comma - names) << " : " << arg1 << " | "; __f(comma + 1, args...);
}
void file_i_o() {
ios_base::sync_with_stdio(0);
cin.tie(0); cout.tie(0);
#ifndef ONLINE_JUDGE
freopen("input.txt", "r", stdin);
//freopen("output.txt", "w", stdout);
#endif
}
//---------------------------Hello there----------------------------
void solve(int test_case) {
$1
}
int32_t main(int32_t argc, char const *argv[]) {
file_i_o();
clock_t myclock = clock();
int tc;
cin >> tc;
for (int i = 1; i <= tc; ++i) {
solve(i);
}
cerr << "Run time: " << ((double)(clock() - myclock)/CLOCKS_PER_SEC) * 1000 << " ms" << endl;
return 0;
}
]]></content>
<!-- Optional: Set a tabTrigger to define how to trigger the snippet -->
<tabTrigger>kickstart</tabTrigger>
<!-- Optional: Set a scope to limit where the snippet will trigger -->
<!-- <scope>source.cpp</scope> -->
</snippet>