forked from jpcsousa/codejam
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtemplate.cpp
More file actions
141 lines (133 loc) · 3.96 KB
/
template.cpp
File metadata and controls
141 lines (133 loc) · 3.96 KB
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
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
#include <algorithm>
#include <bitset>
#include <cassert>
#include <cfloat>
#include <climits>
#include <cmath>
#include <complex>
#include <cstddef>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <ctime>
#include <deque>
#include <fstream>
#include <functional>
#include <iomanip>
#include <iostream>
#include <iterator>
#include <list>
#include <limits>
#include <map>
#include <memory>
#include <numeric>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <string>
#include <utility>
#include <vector>
using namespace std;
#define _USE_MATH_DEFINES // exposes constants, eg. M_PI
#define S(n) scanf("%d",&n)
#define SLL(n) scanf("%lld",&n)
#define SD(n) scanf("%lf",&n)
#define SS(n) scanf("%s",n)
#define INF INT_MAX
#define LINF LLONG_MAX
#define EPS std::numeric_limits<double>::epsilon()
#define ABS(x) ((x)<0?-(x):(x))
#define FOR(i,a,b) for(int i=a;i<b;++i)
#define RFOR(i,a,b) for(int i=(a)-1,_b(b);i>=_b;--i)
#define REP(i,n) for(int (i)=0;(i)<(int)(n);++(i))
#define RREP(i,n) for(int (i)=n;(i)>=(int)0;--(i))
#define DREP(a) sort(all(a)); a.erase(unique(all(a)),a.end())
#define INDEX(arr,ind) (lower_bound(all(arr),ind)-arr.begin())
#define FOREACH(c,itr) for(__typeof((c).begin()) itr=(c).begin();itr!=(c).end();++itr)
#define mp make_pair
#define pb push_back
#define tri(a,b,c) mp(a,mp(b,c))
#define fst first
#define snd second
//#define FILL(a,v) memset(a,v,sizeof(a))
#define SQT(a) ((a)*(a))
//#define MAX(a,b) ((a)>(b)?(a):(b))
//#define MIN(a,b) ((a)<(b)?(a):(b))
#define ALL(x) x.begin(),x.end()
#define SZ(v) ((int)(v.size()))
#define LOG(a) (cerr<<"\tline#"<<__LINE__<<": "#a" = "<<(a)<<endl)
#define DBG(args...) {cerr<<"\tcase#"<<(cc+1)<<": ";dbg,args;cerr<<endl;}
struct debugger {
template<typename T> debugger& operator, (const T& v) {
cerr << v << " ";
return *this;
}
} dbg;
typedef long long LL;
typedef long long ll;
typedef unsigned long long ULL;
typedef unsigned int uint;
typedef pair<int, int> PII;
typedef pair<LL, LL> PLL;
typedef pair<int, PII> TRI;
typedef vector<int> VI;
typedef vector<LL> VL;
typedef vector<string> VS;
typedef vector<PII> VII;
typedef vector<PLL> VLL;
typedef vector<TRI> VT;
typedef vector<VI> VVI;
typedef vector<VL> VVL;
typedef vector<VII> VVII;
typedef vector<VLL> VVLL;
typedef vector<VT> VVT;
typedef complex<double> pt;
typedef complex<LL> pti;
const double PI = M_PI;
template<class T> inline T gcd(T a, T b)
{
return b ? gcd(b, a % b) : a;
}
inline double round(double x)
{
const double sd = 100; // accuracy = 2 dp
return int(x * sd + (x < 0 ? -0.5 : 0.5)) / sd;
}
inline int cmp(double x, double y = 0, double tol = EPS)
{
return (x <= y + tol) ? (x + tol < y) ? -1 : 0 : 1;
}
template<typename T> inline void print(T *array, int size)
{
printf("\tarray[] = [");
for(int i = 0; i < size; ++i) {
printf("%lld", (LL)array[i]);
if(i < size - 1) printf(" ");
}
printf("]\n");
}
template<typename T> inline void print(T **array, int size1, int size2)
{
printf("\tarray[][] = [");
for(int i = 0; i < size1; ++i) {
for(int j = 0; j < size2; ++j) {
printf("%lld", (LL)array[i][j]);
if(j < size2 - 1) printf(" ");
}
printf("]\n");
}
}
/////////////////////////////////////////////////////////////////////////////
int T;
int main()
{
//clock_t start = clock();
scanf("%d", &T);
REP(cc, T) {
printf("Case #%d: %d\n", cc + 1, 0);
}
//fprintf(stderr, "*** Total time: %.3lf seconds ***\n",
// ((clock() - start) / (double) CLOCKS_PER_SEC));
return 0;
}