Skip to content

Instantly share code, notes, and snippets.

View viliml's full-sized avatar

Vilim Lendvaj viliml

  • Popovača, Hrvatska
View GitHub Profile
@viliml
viliml / friend.cpp
Created July 4, 2016 13:24
IOI 2014. day 2
#include "friend.h"
#include <bits/stdc++.h>
using namespace std;
const int MAXN = 100100;
int take[MAXN], dont[MAXN];
#include <bits/stdc++.h>
using namespace std;
const int MAXN = 100100;
int n, k;
int arr[MAXN];
vector<int> edges[MAXN];
int cost[MAXN];
#include <bits/stdc++.h>
using namespace std;
const int MAXN = 300000;
int color[MAXN];
vector<int> edges[MAXN];
long long cnt[MAXN][5];
long long cnt2[MAXN][5][5];
#include "scales.h"
#include <map>
#include <set>
#include <cassert>
#include <algorithm>
using namespace std;
inline int _getMedian(int arr[6], int a, int b, int c)
{
#include "boxes.h"
#include <algorithm>
using namespace std;
const int MAXN = 5<<22;
long long pref[MAXN], suff[MAXN];
long long delivery(int n, int k, int l, int p[])
#include "horses.h"
#include <set>
#include <iostream>
using namespace std;
typedef long long llint;
const int MAXN = 1<<19;
const llint MAX = 1<<30;
#include <bits/stdc++.h>
using namespace std;
const int INF = 1<<20;
string s;
template<typename T1, typename T2>
inline ostream& operator<<(ostream& in, const pair<T1, T2>& x)
#include <bits/stdc++.h>
using namespace std;
using llint = long long;
const int MAXN = 1<<19;
const llint INF = 1ll<<60;
struct fair
#include <bits/stdc++.h>
using namespace std;
using llint = long long;
const int MAXN = 100100;
const llint MOD = 1e9;
int n;
pair<int, int> points[MAXN];
#include "question.h"
using namespace std;
// Dummy implmenentation.
// No communication between two namespaces please.
namespace PlayerA
{
int arr[13] = {1, 1, 2, 3, 6, 10, 20, 35, 70, 126, 252, 462, 924};